diff --git a/CHANGELOG.md b/CHANGELOG.md index c018b50b2..4103468fd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,42 @@ This release changes the pinned API version to 2026-05-27.private. * Add support for `canonical_path` on `EventsV2CoreHealthTrafficVolumeDropFiringEvent` and `EventsV2CoreHealthTrafficVolumeDropResolvedEvent` * Add support for event notifications `V2CoreHealthElementsErrorFiringEvent`, `V2CoreHealthElementsErrorResolvedEvent`, `V2CoreHealthInvoiceCountDroppedFiringEvent`, and `V2CoreHealthInvoiceCountDroppedResolvedEvent` +## 19.2.0 - 2026-05-27 +This release changes the pinned API version to 2026-05-27.dahlia. + +* [#1864](https://github.com/stripe/stripe-ruby/pull/1864) Update generated code + * Add support for new resource `V2::Commerce::ProductCatalogImport` + * Add support for `create` and `retrieve` methods on resource `V2::Commerce::ProductCatalogImport` + * Add support for `bizum_payments` and `scalapay_payments` on `Account::Capability`, `AccountCreateParams::Capability`, and `AccountUpdateParams::Capability` + * Add support for `automatic_transfer_rules_by_currency` on `BalanceSettings::Payment::Payout` and `BalanceSettingsUpdateParams::Payment::Payout` + * Add support for `start_of_day` on `BalanceSettings::Payment::SettlementTiming` and `BalanceSettingsUpdateParams::Payment::SettlementTiming` + * Add support for `description` on `ChargeCreateParams::TransferDatum`, `PaymentIntent::TransferDatum`, `PaymentIntentCreateParams::TransferDatum`, and `PaymentIntentUpdateParams::TransferDatum` + * Add support for `bizum` on `Charge::PaymentMethodDetail`, `ConfirmationToken::PaymentMethodPreview`, `ConfirmationTokenCreateParams::PaymentMethodDatum`, `PaymentAttemptRecord::PaymentMethodDetail`, `PaymentIntent::PaymentMethodOption`, `PaymentIntentConfirmParams::PaymentMethodDatum`, `PaymentIntentConfirmParams::PaymentMethodOption`, `PaymentIntentCreateParams::PaymentMethodDatum`, `PaymentIntentCreateParams::PaymentMethodOption`, `PaymentIntentUpdateParams::PaymentMethodDatum`, `PaymentIntentUpdateParams::PaymentMethodOption`, `PaymentMethodConfigurationCreateParams`, `PaymentMethodConfigurationUpdateParams`, `PaymentMethodConfiguration`, `PaymentMethodCreateParams`, `PaymentMethod`, `PaymentRecord::PaymentMethodDetail`, `SetupIntent::PaymentMethodOption`, `SetupIntentConfirmParams::PaymentMethodDatum`, `SetupIntentConfirmParams::PaymentMethodOption`, `SetupIntentCreateParams::PaymentMethodDatum`, `SetupIntentCreateParams::PaymentMethodOption`, `SetupIntentUpdateParams::PaymentMethodDatum`, and `SetupIntentUpdateParams::PaymentMethodOption` + * Add support for `scalapay` on `Charge::PaymentMethodDetail`, `Checkout::Session::PaymentMethodOption`, `Checkout::SessionCreateParams::PaymentMethodOption`, `ConfirmationToken::PaymentMethodPreview`, `ConfirmationTokenCreateParams::PaymentMethodDatum`, `PaymentAttemptRecord::PaymentMethodDetail`, `PaymentIntent::PaymentMethodOption`, `PaymentIntentConfirmParams::PaymentMethodDatum`, `PaymentIntentConfirmParams::PaymentMethodOption`, `PaymentIntentCreateParams::PaymentMethodDatum`, `PaymentIntentCreateParams::PaymentMethodOption`, `PaymentIntentUpdateParams::PaymentMethodDatum`, `PaymentIntentUpdateParams::PaymentMethodOption`, `PaymentMethodConfigurationCreateParams`, `PaymentMethodConfigurationUpdateParams`, `PaymentMethodConfiguration`, `PaymentMethodCreateParams`, `PaymentMethod`, `PaymentRecord::PaymentMethodDetail`, `Refund::DestinationDetail`, `SetupIntentConfirmParams::PaymentMethodDatum`, `SetupIntentCreateParams::PaymentMethodDatum`, and `SetupIntentUpdateParams::PaymentMethodDatum` + * Add support for `mandate` on `Charge::PaymentMethodDetail::Twint`, `PaymentAttemptRecord::PaymentMethodDetail::Twint`, and `PaymentRecord::PaymentMethodDetail::Twint` + * Change type of `Checkout::SessionCreateParams::PaymentMethodOption::Twint.setup_future_usage`, `PaymentIntentConfirmParams::PaymentMethodOption::Twint.setup_future_usage`, `PaymentIntentCreateParams::PaymentMethodOption::Twint.setup_future_usage`, and `PaymentIntentUpdateParams::PaymentMethodOption::Twint.setup_future_usage` from `literal('none')` to `enum('none'|'off_session')` + * ⚠️ Change type of `Checkout::Session::PaymentMethodOption::Twint.setup_future_usage` and `PaymentIntent::PaymentMethodOption::Twint.setup_future_usage` from `literal('none')` to `enum('none'|'off_session')` + * Add support for `credited_items` on `InvoiceItem::ProrationDetail` + * Add support for `discountable` on `InvoiceCreatePreviewParams::ScheduleDetail::Phase::AddInvoiceItem`, `SubscriptionCreateParams::AddInvoiceItem`, `SubscriptionSchedule::Phase::AddInvoiceItem`, `SubscriptionScheduleCreateParams::Phase::AddInvoiceItem`, `SubscriptionScheduleUpdateParams::Phase::AddInvoiceItem`, and `SubscriptionUpdateParams::AddInvoiceItem` + * Add support for `billing_schedules` on `InvoiceCreatePreviewParams::SubscriptionDetail`, `SubscriptionCreateParams`, `SubscriptionUpdateParams`, and `Subscription` + * Add support for `amount_paid_off_stripe` on `Invoice` + * Add support for `twint` on `Mandate::PaymentMethodDetail` and `SetupAttempt::PaymentMethodDetail` + * Add support for `metadata` on `PaymentIntent::TransferDatum`, `PaymentIntentCreateParams::TransferDatum`, `PaymentIntentUpdateParams::TransferDatum`, and `Subscription::PendingUpdate` + * Add support for `payment_data` on `PaymentIntent::TransferDatum`, `PaymentIntentCreateParams::TransferDatum`, and `PaymentIntentUpdateParams::TransferDatum` + * Add support for `blik_authorize` on `PaymentIntent::NextAction` and `SetupIntent::NextAction` + * Add support for `payment_method_options` on `PaymentLinkCreateParams`, `PaymentLinkUpdateParams`, and `PaymentLink` + * Add support for `active` on `PaymentMethodConfigurationListParams` + * Add support for `billed_until` on `SubscriptionItem` + * Add support for `discount` and `discounts` on `Subscription::PendingUpdate` + * Add support for `verifone_m425`, `verifone_p630`, `verifone_ux700`, and `verifone_v660p` on `Terminal::ConfigurationCreateParams`, `Terminal::ConfigurationUpdateParams`, and `Terminal::Configuration` + * Add support for `api_error` and `print_content` on `Terminal::Reader::Action` + * Add support for `customer` on `TestHelpers::TestClockCreateParams` + * Add support for `signer` on `V2::Core::Account::Identity::BusinessDetail::Document::ProofOfRegistration`, `V2::Core::Account::Identity::BusinessDetail::Document::ProofOfUltimateBeneficialOwnership`, `V2::Core::AccountCreateParams::Identity::BusinessDetail::Document::ProofOfRegistration`, `V2::Core::AccountCreateParams::Identity::BusinessDetail::Document::ProofOfUltimateBeneficialOwnership`, `V2::Core::AccountTokenCreateParams::Identity::BusinessDetail::Document::ProofOfRegistration`, `V2::Core::AccountTokenCreateParams::Identity::BusinessDetail::Document::ProofOfUltimateBeneficialOwnership`, `V2::Core::AccountUpdateParams::Identity::BusinessDetail::Document::ProofOfRegistration`, and `V2::Core::AccountUpdateParams::Identity::BusinessDetail::Document::ProofOfUltimateBeneficialOwnership` + * Add support for `azure_event_grid` on `V2::Core::EventDestinationCreateParams` and `V2::Core::EventDestination` + * Add support for event notifications `V2CommerceProductCatalogImportsFailedEvent`, `V2CommerceProductCatalogImportsProcessingEvent`, `V2CommerceProductCatalogImportsSucceededEvent`, and `V2CommerceProductCatalogImportsSucceededWithErrorsEvent` with related object `V2::Commerce::ProductCatalogImport` +* [#1866](https://github.com/stripe/stripe-ruby/pull/1866) Emit warning when `stripe-notify` header is present in response +* [#1855](https://github.com/stripe/stripe-ruby/pull/1855) Use autoload instead of eager require for generated resource, service, and param files + ## 19.2.0-alpha.6 - 2026-05-20 * [#1865](https://github.com/stripe/stripe-ruby/pull/1865) Update generated code for private-preview * Add support for new resource `PaymentLocationCapability` diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index 3e0fd8d32..759dc3b52 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -1af5aa444ea8141a2d2b8d86e76c73f788f65e09 \ No newline at end of file +656489921ee220b536bc00fc1c8ee7ed528f24e2 \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 30723023b..bd44999eb 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2277 \ No newline at end of file +v2290 \ No newline at end of file diff --git a/lib/stripe/api_requestor.rb b/lib/stripe/api_requestor.rb index 0bf955bbb..bf1991254 100644 --- a/lib/stripe/api_requestor.rb +++ b/lib/stripe/api_requestor.rb @@ -201,6 +201,9 @@ def execute_request(method, path, base_address, ) req_opts = RequestOptions.extract_opts_from_hash(req_opts) + notice = http_resp["stripe-notice"] + warn("WARNING: #{notice}") if notice + resp = interpret_response(http_resp) # If being called from `APIRequestor#request`, put the last response in diff --git a/lib/stripe/api_version.rb b/lib/stripe/api_version.rb index 46d68afe3..8109c666b 100644 --- a/lib/stripe/api_version.rb +++ b/lib/stripe/api_version.rb @@ -3,6 +3,6 @@ module Stripe module ApiVersion - CURRENT = "2026-05-27.preview" + CURRENT = "2026-06-03.preview" end end diff --git a/lib/stripe/event_types.rb b/lib/stripe/event_types.rb index e147416e8..ea0b8cb05 100644 --- a/lib/stripe/event_types.rb +++ b/lib/stripe/event_types.rb @@ -638,6 +638,8 @@ def self.v2_event_types_to_classes Events::V2ReportingReportRunUpdatedEvent.lookup_type => Events::V2ReportingReportRunUpdatedEvent, Events::V2SignalsAccountSignalFraudulentMerchantReadyEvent.lookup_type => Events::V2SignalsAccountSignalFraudulentMerchantReadyEvent, + Events::V2SignalsAccountSignalMerchantDelinquencyReadyEvent.lookup_type => + Events::V2SignalsAccountSignalMerchantDelinquencyReadyEvent, # v2 event types: The end of the section generated from our OpenAPI spec } end @@ -1403,6 +1405,8 @@ def self.event_notification_types_to_classes Events::V2ReportingReportRunUpdatedEventNotification, Events::V2SignalsAccountSignalFraudulentMerchantReadyEventNotification.lookup_type => Events::V2SignalsAccountSignalFraudulentMerchantReadyEventNotification, + Events::V2SignalsAccountSignalMerchantDelinquencyReadyEventNotification.lookup_type => + Events::V2SignalsAccountSignalMerchantDelinquencyReadyEventNotification, # event notification types: The end of the section generated from our OpenAPI spec } end diff --git a/lib/stripe/events/v2_signals_account_signal_merchant_delinquency_ready_event.rb b/lib/stripe/events/v2_signals_account_signal_merchant_delinquency_ready_event.rb new file mode 100644 index 000000000..b662fbcf8 --- /dev/null +++ b/lib/stripe/events/v2_signals_account_signal_merchant_delinquency_ready_event.rb @@ -0,0 +1,44 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module Events + # Occurs when a merchant delinquency signal is ready for an account. + class V2SignalsAccountSignalMerchantDelinquencyReadyEvent < Stripe::V2::Core::Event + def self.lookup_type + "v2.signals.account_signal.merchant_delinquency_ready" + end + + # Retrieves the related object from the API. Makes an API request on every call. + def fetch_related_object + _request( + method: :get, + path: related_object.url, + base_address: :api, + opts: { stripe_context: context, "Stripe-Request-Trigger": "event=#{id}" } + ) + end + attr_reader :related_object + end + + # Occurs when a merchant delinquency signal is ready for an account. + class V2SignalsAccountSignalMerchantDelinquencyReadyEventNotification < Stripe::V2::Core::EventNotification + def self.lookup_type + "v2.signals.account_signal.merchant_delinquency_ready" + end + + attr_reader :related_object + + # Retrieves the AccountSignal related to this EventNotification from the Stripe API. Makes an API request on every call. + def fetch_related_object + resp = @client.raw_request( + :get, + related_object.url, + opts: { stripe_context: context, "Stripe-Request-Trigger": "event=#{id}" }, + usage: ["fetch_related_object"] + ) + @client.deserialize(resp.http_body, api_mode: Util.get_api_mode(related_object.url)) + end + end + end +end diff --git a/lib/stripe/object_types.rb b/lib/stripe/object_types.rb index 26f829424..df5fe0547 100644 --- a/lib/stripe/object_types.rb +++ b/lib/stripe/object_types.rb @@ -62,6 +62,8 @@ def self.object_names_to_classes CustomerBalanceTransaction.object_name => CustomerBalanceTransaction, CustomerCashBalanceTransaction.object_name => CustomerCashBalanceTransaction, CustomerSession.object_name => CustomerSession, + DelegatedCheckout::Order.object_name => DelegatedCheckout::Order, + DelegatedCheckout::OrderEvent.object_name => DelegatedCheckout::OrderEvent, DelegatedCheckout::RequestedSession.object_name => DelegatedCheckout::RequestedSession, Discount.object_name => Discount, Dispute.object_name => Dispute, @@ -219,6 +221,9 @@ def self.v2_object_names_to_classes V2::Billing::CadenceSpendModifier.object_name => V2::Billing::CadenceSpendModifier, V2::Billing::CollectionSetting.object_name => V2::Billing::CollectionSetting, V2::Billing::CollectionSettingVersion.object_name => V2::Billing::CollectionSettingVersion, + V2::Billing::Contract.object_name => V2::Billing::Contract, + V2::Billing::ContractLicensePricingQuantityChange.object_name => + V2::Billing::ContractLicensePricingQuantityChange, V2::Billing::CustomPricingUnit.object_name => V2::Billing::CustomPricingUnit, V2::Billing::Intent.object_name => V2::Billing::Intent, V2::Billing::IntentAction.object_name => V2::Billing::IntentAction, @@ -297,6 +302,7 @@ def self.v2_object_names_to_classes V2::Payments::SettlementAllocationIntentSplit, V2::Reporting::Report.object_name => V2::Reporting::Report, V2::Reporting::ReportRun.object_name => V2::Reporting::ReportRun, + V2::Signals::AccountSignal.object_name => V2::Signals::AccountSignal, V2::Tax::ManualRule.object_name => V2::Tax::ManualRule, # v2 object classes: The end of the section generated from our OpenAPI spec } diff --git a/lib/stripe/params.rb b/lib/stripe/params.rb index 55835f64a..1be327139 100644 --- a/lib/stripe/params.rb +++ b/lib/stripe/params.rb @@ -456,9 +456,12 @@ module Climate end module DelegatedCheckout + autoload :OrderRetrieveParams, "stripe/params/delegated_checkout/order_retrieve_params" autoload :RequestedSessionConfirmParams, "stripe/params/delegated_checkout/requested_session_confirm_params" autoload :RequestedSessionCreateParams, "stripe/params/delegated_checkout/requested_session_create_params" autoload :RequestedSessionExpireParams, "stripe/params/delegated_checkout/requested_session_expire_params" + autoload :RequestedSessionListOrdersParams, "stripe/params/delegated_checkout/requested_session_list_orders_params" + autoload :RequestedSessionOrderListParams, "stripe/params/delegated_checkout/requested_session_order_list_params" autoload :RequestedSessionRetrieveParams, "stripe/params/delegated_checkout/requested_session_retrieve_params" autoload :RequestedSessionUpdateParams, "stripe/params/delegated_checkout/requested_session_update_params" end @@ -873,6 +876,12 @@ module Billing autoload :CollectionSettingListParams, "stripe/params/v2/billing/collection_setting_list_params" autoload :CollectionSettingRetrieveParams, "stripe/params/v2/billing/collection_setting_retrieve_params" autoload :CollectionSettingUpdateParams, "stripe/params/v2/billing/collection_setting_update_params" + autoload :ContractActivateParams, "stripe/params/v2/billing/contract_activate_params" + autoload :ContractCancelParams, "stripe/params/v2/billing/contract_cancel_params" + autoload :ContractCreateParams, "stripe/params/v2/billing/contract_create_params" + autoload :ContractListParams, "stripe/params/v2/billing/contract_list_params" + autoload :ContractRetrieveParams, "stripe/params/v2/billing/contract_retrieve_params" + autoload :ContractUpdateParams, "stripe/params/v2/billing/contract_update_params" autoload :CustomPricingUnitCreateParams, "stripe/params/v2/billing/custom_pricing_unit_create_params" autoload :CustomPricingUnitListParams, "stripe/params/v2/billing/custom_pricing_unit_list_params" autoload :CustomPricingUnitRetrieveParams, "stripe/params/v2/billing/custom_pricing_unit_retrieve_params" @@ -948,6 +957,13 @@ module CollectionSettings autoload :VersionRetrieveParams, "stripe/params/v2/billing/collection_settings/version_retrieve_params" end + module Contracts + module LicensePricing + autoload :QuantityChangeListQuantityChangesParams, + "stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params" + end + end + module Intents autoload :ActionListParams, "stripe/params/v2/billing/intents/action_list_params" autoload :ActionRetrieveParams, "stripe/params/v2/billing/intents/action_retrieve_params" @@ -1209,6 +1225,11 @@ module Reporting autoload :ReportRunRetrieveParams, "stripe/params/v2/reporting/report_run_retrieve_params" end + module Signals + autoload :AccountSignalListParams, "stripe/params/v2/signals/account_signal_list_params" + autoload :AccountSignalRetrieveParams, "stripe/params/v2/signals/account_signal_retrieve_params" + end + module Tax autoload :ManualRuleCreateParams, "stripe/params/v2/tax/manual_rule_create_params" autoload :ManualRuleDeactivateParams, "stripe/params/v2/tax/manual_rule_deactivate_params" @@ -1390,9 +1411,12 @@ module Stripe stripe/params/customer_tax_id_list_params stripe/params/customer_tax_id_retrieve_params stripe/params/customer_update_params + stripe/params/delegated_checkout/order_retrieve_params stripe/params/delegated_checkout/requested_session_confirm_params stripe/params/delegated_checkout/requested_session_create_params stripe/params/delegated_checkout/requested_session_expire_params + stripe/params/delegated_checkout/requested_session_list_orders_params + stripe/params/delegated_checkout/requested_session_order_list_params stripe/params/delegated_checkout/requested_session_retrieve_params stripe/params/delegated_checkout/requested_session_update_params stripe/params/dispute_close_params @@ -1972,6 +1996,13 @@ module Stripe stripe/params/v2/billing/collection_setting_update_params stripe/params/v2/billing/collection_settings/version_list_params stripe/params/v2/billing/collection_settings/version_retrieve_params + stripe/params/v2/billing/contract_activate_params + stripe/params/v2/billing/contract_cancel_params + stripe/params/v2/billing/contract_create_params + stripe/params/v2/billing/contract_list_params + stripe/params/v2/billing/contract_retrieve_params + stripe/params/v2/billing/contract_update_params + stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params stripe/params/v2/billing/custom_pricing_unit_create_params stripe/params/v2/billing/custom_pricing_unit_list_params stripe/params/v2/billing/custom_pricing_unit_retrieve_params @@ -2203,6 +2234,8 @@ module Stripe stripe/params/v2/reporting/report_retrieve_params stripe/params/v2/reporting/report_run_create_params stripe/params/v2/reporting/report_run_retrieve_params + stripe/params/v2/signals/account_signal_list_params + stripe/params/v2/signals/account_signal_retrieve_params stripe/params/v2/tax/manual_rule_create_params stripe/params/v2/tax/manual_rule_deactivate_params stripe/params/v2/tax/manual_rule_list_params diff --git a/lib/stripe/params/account_create_params.rb b/lib/stripe/params/account_create_params.rb index 1f09ea13e..a520c675c 100644 --- a/lib/stripe/params/account_create_params.rb +++ b/lib/stripe/params/account_create_params.rb @@ -1904,6 +1904,37 @@ def initialize( end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + attr_accessor :city + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + attr_accessor :country + # Address line 1, such as the street, PO Box, or company name. + attr_accessor :line1 + # Address line 2, such as the apartment, suite, unit, or building. + attr_accessor :line2 + # ZIP or postal code. + attr_accessor :postal_code + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + attr_accessor :state + + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ) + @city = city + @country = country + @line1 = line1 + @line2 = line2 + @postal_code = postal_code + @state = state + end + end + class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. attr_accessor :day @@ -2041,6 +2072,8 @@ def initialize(additional_document: nil, document: nil) attr_accessor :address_kana # The Kanji variation of the individual's primary address (Japan only). attr_accessor :address_kanji + # Attribute for param field birth_address + attr_accessor :birth_address # The individual's date of birth. attr_accessor :dob # The individual's email address. @@ -2090,6 +2123,7 @@ def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, @@ -2116,6 +2150,7 @@ def initialize( @address = address @address_kana = address_kana @address_kanji = address_kanji + @birth_address = birth_address @dob = dob @email = email @first_name = first_name diff --git a/lib/stripe/params/account_person_create_params.rb b/lib/stripe/params/account_person_create_params.rb index 74fd2f8fc..a6a9e2b0d 100644 --- a/lib/stripe/params/account_person_create_params.rb +++ b/lib/stripe/params/account_person_create_params.rb @@ -120,6 +120,30 @@ def initialize( end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + attr_accessor :city + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + attr_accessor :country + # Address line 1, such as the street, PO Box, or company name. + attr_accessor :line1 + # Address line 2, such as the apartment, suite, unit, or building. + attr_accessor :line2 + # ZIP or postal code. + attr_accessor :postal_code + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + attr_accessor :state + + def initialize(city: nil, country: nil, line1: nil, line2: nil, postal_code: nil, state: nil) + @city = city + @country = country + @line1 = line1 + @line2 = line2 + @postal_code = postal_code + @state = state + end + end + class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. attr_accessor :day @@ -343,6 +367,8 @@ def initialize(additional_document: nil, document: nil) attr_accessor :address_kana # The Kanji variation of the person's address (Japan only). attr_accessor :address_kanji + # The person's place of birth. + attr_accessor :birth_address # The person's date of birth. attr_accessor :dob # Documents that may be submitted to satisfy various informational requests. @@ -403,6 +429,7 @@ def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, @@ -435,6 +462,7 @@ def initialize( @address = address @address_kana = address_kana @address_kanji = address_kanji + @birth_address = birth_address @dob = dob @documents = documents @email = email diff --git a/lib/stripe/params/account_person_update_params.rb b/lib/stripe/params/account_person_update_params.rb index 160f14101..3d5985681 100644 --- a/lib/stripe/params/account_person_update_params.rb +++ b/lib/stripe/params/account_person_update_params.rb @@ -120,6 +120,30 @@ def initialize( end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + attr_accessor :city + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + attr_accessor :country + # Address line 1, such as the street, PO Box, or company name. + attr_accessor :line1 + # Address line 2, such as the apartment, suite, unit, or building. + attr_accessor :line2 + # ZIP or postal code. + attr_accessor :postal_code + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + attr_accessor :state + + def initialize(city: nil, country: nil, line1: nil, line2: nil, postal_code: nil, state: nil) + @city = city + @country = country + @line1 = line1 + @line2 = line2 + @postal_code = postal_code + @state = state + end + end + class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. attr_accessor :day @@ -343,6 +367,8 @@ def initialize(additional_document: nil, document: nil) attr_accessor :address_kana # The Kanji variation of the person's address (Japan only). attr_accessor :address_kanji + # The person's place of birth. + attr_accessor :birth_address # The person's date of birth. attr_accessor :dob # Documents that may be submitted to satisfy various informational requests. @@ -403,6 +429,7 @@ def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, @@ -435,6 +462,7 @@ def initialize( @address = address @address_kana = address_kana @address_kanji = address_kanji + @birth_address = birth_address @dob = dob @documents = documents @email = email diff --git a/lib/stripe/params/account_update_params.rb b/lib/stripe/params/account_update_params.rb index 5336089af..55ab40afc 100644 --- a/lib/stripe/params/account_update_params.rb +++ b/lib/stripe/params/account_update_params.rb @@ -1823,6 +1823,37 @@ def initialize( end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + attr_accessor :city + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + attr_accessor :country + # Address line 1, such as the street, PO Box, or company name. + attr_accessor :line1 + # Address line 2, such as the apartment, suite, unit, or building. + attr_accessor :line2 + # ZIP or postal code. + attr_accessor :postal_code + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + attr_accessor :state + + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ) + @city = city + @country = country + @line1 = line1 + @line2 = line2 + @postal_code = postal_code + @state = state + end + end + class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. attr_accessor :day @@ -1960,6 +1991,8 @@ def initialize(additional_document: nil, document: nil) attr_accessor :address_kana # The Kanji variation of the individual's primary address (Japan only). attr_accessor :address_kanji + # Attribute for param field birth_address + attr_accessor :birth_address # The individual's date of birth. attr_accessor :dob # The individual's email address. @@ -2009,6 +2042,7 @@ def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, @@ -2035,6 +2069,7 @@ def initialize( @address = address @address_kana = address_kana @address_kanji = address_kanji + @birth_address = birth_address @dob = dob @email = email @first_name = first_name diff --git a/lib/stripe/params/delegated_checkout/order_retrieve_params.rb b/lib/stripe/params/delegated_checkout/order_retrieve_params.rb new file mode 100644 index 000000000..7c1c035d7 --- /dev/null +++ b/lib/stripe/params/delegated_checkout/order_retrieve_params.rb @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module DelegatedCheckout + class OrderRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + attr_accessor :expand + + def initialize(expand: nil) + @expand = expand + end + end + end +end diff --git a/lib/stripe/params/delegated_checkout/requested_session_list_orders_params.rb b/lib/stripe/params/delegated_checkout/requested_session_list_orders_params.rb new file mode 100644 index 000000000..3dc49f3d7 --- /dev/null +++ b/lib/stripe/params/delegated_checkout/requested_session_list_orders_params.rb @@ -0,0 +1,24 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module DelegatedCheckout + class RequestedSessionListOrdersParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + attr_accessor :ending_before + # Specifies which fields in the response should be expanded. + attr_accessor :expand + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + attr_accessor :limit + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + attr_accessor :starting_after + + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil) + @ending_before = ending_before + @expand = expand + @limit = limit + @starting_after = starting_after + end + end + end +end diff --git a/lib/stripe/params/delegated_checkout/requested_session_order_list_params.rb b/lib/stripe/params/delegated_checkout/requested_session_order_list_params.rb new file mode 100644 index 000000000..d7c73ea22 --- /dev/null +++ b/lib/stripe/params/delegated_checkout/requested_session_order_list_params.rb @@ -0,0 +1,24 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module DelegatedCheckout + class RequestedSessionOrderListParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + attr_accessor :ending_before + # Specifies which fields in the response should be expanded. + attr_accessor :expand + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + attr_accessor :limit + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + attr_accessor :starting_after + + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil) + @ending_before = ending_before + @expand = expand + @limit = limit + @starting_after = starting_after + end + end + end +end diff --git a/lib/stripe/params/payment_intent_confirm_params.rb b/lib/stripe/params/payment_intent_confirm_params.rb index ed4caa911..6fbc20ca5 100644 --- a/lib/stripe/params/payment_intent_confirm_params.rb +++ b/lib/stripe/params/payment_intent_confirm_params.rb @@ -3332,12 +3332,15 @@ def initialize(staged_purchase: nil) @staged_purchase = staged_purchase end end + # The category of digital asset being acquired through this account funding transaction. + attr_accessor :digital_asset_category # Details for a liquid asset (crypto or security) funding transaction. attr_accessor :liquid_asset # Details for a wallet funding transaction. attr_accessor :wallet - def initialize(liquid_asset: nil, wallet: nil) + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil) + @digital_asset_category = digital_asset_category @liquid_asset = liquid_asset @wallet = wallet end @@ -3640,12 +3643,15 @@ def initialize(staged_purchase: nil) @staged_purchase = staged_purchase end end + # The category of digital asset being acquired through this account funding transaction. + attr_accessor :digital_asset_category # Details for a liquid asset (crypto or security) funding transaction. attr_accessor :liquid_asset # Details for a wallet funding transaction. attr_accessor :wallet - def initialize(liquid_asset: nil, wallet: nil) + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil) + @digital_asset_category = digital_asset_category @liquid_asset = liquid_asset @wallet = wallet end @@ -3735,9 +3741,12 @@ class Crypto < ::Stripe::RequestParams class DepositOptions < ::Stripe::RequestParams # The blockchain networks to support for deposits. Learn more about [supported networks and tokens](https://docs.stripe.com/payments/deposit-mode-stablecoin-payments#token-and-network-support). attr_accessor :networks + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + attr_accessor :static_address - def initialize(networks: nil) + def initialize(networks: nil, static_address: nil) @networks = networks + @static_address = static_address end end # Specific configuration for this PaymentIntent when the mode is `deposit`. diff --git a/lib/stripe/params/payment_intent_create_params.rb b/lib/stripe/params/payment_intent_create_params.rb index 29dac55bb..326a64d7f 100644 --- a/lib/stripe/params/payment_intent_create_params.rb +++ b/lib/stripe/params/payment_intent_create_params.rb @@ -3346,12 +3346,15 @@ def initialize(staged_purchase: nil) @staged_purchase = staged_purchase end end + # The category of digital asset being acquired through this account funding transaction. + attr_accessor :digital_asset_category # Details for a liquid asset (crypto or security) funding transaction. attr_accessor :liquid_asset # Details for a wallet funding transaction. attr_accessor :wallet - def initialize(liquid_asset: nil, wallet: nil) + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil) + @digital_asset_category = digital_asset_category @liquid_asset = liquid_asset @wallet = wallet end @@ -3654,12 +3657,15 @@ def initialize(staged_purchase: nil) @staged_purchase = staged_purchase end end + # The category of digital asset being acquired through this account funding transaction. + attr_accessor :digital_asset_category # Details for a liquid asset (crypto or security) funding transaction. attr_accessor :liquid_asset # Details for a wallet funding transaction. attr_accessor :wallet - def initialize(liquid_asset: nil, wallet: nil) + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil) + @digital_asset_category = digital_asset_category @liquid_asset = liquid_asset @wallet = wallet end @@ -3749,9 +3755,12 @@ class Crypto < ::Stripe::RequestParams class DepositOptions < ::Stripe::RequestParams # The blockchain networks to support for deposits. Learn more about [supported networks and tokens](https://docs.stripe.com/payments/deposit-mode-stablecoin-payments#token-and-network-support). attr_accessor :networks + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + attr_accessor :static_address - def initialize(networks: nil) + def initialize(networks: nil, static_address: nil) @networks = networks + @static_address = static_address end end # Specific configuration for this PaymentIntent when the mode is `deposit`. @@ -6164,22 +6173,14 @@ def initialize( end class PaymentsOrchestration < ::Stripe::RequestParams - class PaymentDetails < ::Stripe::RequestParams - # Merchant-provided reference for this payment, used for reconciliation. - attr_accessor :reference - - def initialize(reference: nil) - @reference = reference - end - end # Whether this feature is enabled. attr_accessor :enabled - # Payment-level details for the orchestrated payment. - attr_accessor :payment_details + # Merchant-provided reference for this payment, used for reconciliation. + attr_accessor :payment_reference - def initialize(enabled: nil, payment_details: nil) + def initialize(enabled: nil, payment_reference: nil) @enabled = enabled - @payment_details = payment_details + @payment_reference = payment_reference end end diff --git a/lib/stripe/params/payment_intent_update_params.rb b/lib/stripe/params/payment_intent_update_params.rb index 6fdff46f1..e1d0d8076 100644 --- a/lib/stripe/params/payment_intent_update_params.rb +++ b/lib/stripe/params/payment_intent_update_params.rb @@ -3324,12 +3324,15 @@ def initialize(staged_purchase: nil) @staged_purchase = staged_purchase end end + # The category of digital asset being acquired through this account funding transaction. + attr_accessor :digital_asset_category # Details for a liquid asset (crypto or security) funding transaction. attr_accessor :liquid_asset # Details for a wallet funding transaction. attr_accessor :wallet - def initialize(liquid_asset: nil, wallet: nil) + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil) + @digital_asset_category = digital_asset_category @liquid_asset = liquid_asset @wallet = wallet end @@ -3632,12 +3635,15 @@ def initialize(staged_purchase: nil) @staged_purchase = staged_purchase end end + # The category of digital asset being acquired through this account funding transaction. + attr_accessor :digital_asset_category # Details for a liquid asset (crypto or security) funding transaction. attr_accessor :liquid_asset # Details for a wallet funding transaction. attr_accessor :wallet - def initialize(liquid_asset: nil, wallet: nil) + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil) + @digital_asset_category = digital_asset_category @liquid_asset = liquid_asset @wallet = wallet end @@ -3727,9 +3733,12 @@ class Crypto < ::Stripe::RequestParams class DepositOptions < ::Stripe::RequestParams # The blockchain networks to support for deposits. Learn more about [supported networks and tokens](https://docs.stripe.com/payments/deposit-mode-stablecoin-payments#token-and-network-support). attr_accessor :networks + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + attr_accessor :static_address - def initialize(networks: nil) + def initialize(networks: nil, static_address: nil) @networks = networks + @static_address = static_address end end # Specific configuration for this PaymentIntent when the mode is `deposit`. diff --git a/lib/stripe/params/payment_location_capability_list_params.rb b/lib/stripe/params/payment_location_capability_list_params.rb index b12871ea5..4837b5e1b 100644 --- a/lib/stripe/params/payment_location_capability_list_params.rb +++ b/lib/stripe/params/payment_location_capability_list_params.rb @@ -5,7 +5,7 @@ module Stripe class PaymentLocationCapabilityListParams < ::Stripe::RequestParams # Specifies which fields in the response should be expanded. attr_accessor :expand - # The location for which the capabilities enable functionality. + # The payment location that the capabilities enable functionality for. attr_accessor :location def initialize(expand: nil, location: nil) diff --git a/lib/stripe/params/payment_location_capability_retrieve_params.rb b/lib/stripe/params/payment_location_capability_retrieve_params.rb index d1b75fc23..ef0f56d85 100644 --- a/lib/stripe/params/payment_location_capability_retrieve_params.rb +++ b/lib/stripe/params/payment_location_capability_retrieve_params.rb @@ -5,7 +5,7 @@ module Stripe class PaymentLocationCapabilityRetrieveParams < ::Stripe::RequestParams # Specifies which fields in the response should be expanded. attr_accessor :expand - # The payment location for which the capability enables functionality. + # The payment location that the capability enables functionality for. attr_accessor :location def initialize(expand: nil, location: nil) diff --git a/lib/stripe/params/payment_location_capability_update_params.rb b/lib/stripe/params/payment_location_capability_update_params.rb index f7fe2124b..0739564be 100644 --- a/lib/stripe/params/payment_location_capability_update_params.rb +++ b/lib/stripe/params/payment_location_capability_update_params.rb @@ -5,7 +5,7 @@ module Stripe class PaymentLocationCapabilityUpdateParams < ::Stripe::RequestParams # Specifies which fields in the response should be expanded. attr_accessor :expand - # The location for which the capability enables functionality. + # The location that the capability enables functionality for. attr_accessor :location # To request a new capability for the location, set this to `true`. You can remove it from the location by passing `false`. attr_accessor :requested diff --git a/lib/stripe/params/payment_location_list_params.rb b/lib/stripe/params/payment_location_list_params.rb index e05d6a723..3d9aa93b4 100644 --- a/lib/stripe/params/payment_location_list_params.rb +++ b/lib/stripe/params/payment_location_list_params.rb @@ -3,11 +3,20 @@ module Stripe class PaymentLocationListParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + attr_accessor :ending_before # Specifies which fields in the response should be expanded. attr_accessor :expand + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + attr_accessor :limit + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + attr_accessor :starting_after - def initialize(expand: nil) + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil) + @ending_before = ending_before @expand = expand + @limit = limit + @starting_after = starting_after end end end diff --git a/lib/stripe/params/payment_location_update_params.rb b/lib/stripe/params/payment_location_update_params.rb index 1c5602aca..0ace66a71 100644 --- a/lib/stripe/params/payment_location_update_params.rb +++ b/lib/stripe/params/payment_location_update_params.rb @@ -43,7 +43,7 @@ def initialize(siret: nil) attr_accessor :display_name # Specifies which fields in the response should be expanded. attr_accessor :expand - # Pass true when updating location fields that will trigger onboarding review for any of the location's active location capabilities. If this parameter is not set to true, updates that would trigger onboarding review will fail. Only applicable for locations with active location capabilities. + # Pass true when updating location fields that trigger onboarding review for any of the location's active location capabilities. If this parameter isn't set to true, updates that would trigger onboarding review fail. Only applicable for locations with active location capabilities. attr_accessor :onboarding_data_update_acknowledged def initialize( diff --git a/lib/stripe/params/token_create_params.rb b/lib/stripe/params/token_create_params.rb index cb133e6df..132eac479 100644 --- a/lib/stripe/params/token_create_params.rb +++ b/lib/stripe/params/token_create_params.rb @@ -389,6 +389,37 @@ def initialize( end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + attr_accessor :city + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + attr_accessor :country + # Address line 1, such as the street, PO Box, or company name. + attr_accessor :line1 + # Address line 2, such as the apartment, suite, unit, or building. + attr_accessor :line2 + # ZIP or postal code. + attr_accessor :postal_code + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + attr_accessor :state + + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ) + @city = city + @country = country + @line1 = line1 + @line2 = line2 + @postal_code = postal_code + @state = state + end + end + class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. attr_accessor :day @@ -526,6 +557,8 @@ def initialize(additional_document: nil, document: nil) attr_accessor :address_kana # The Kanji variation of the individual's primary address (Japan only). attr_accessor :address_kanji + # Attribute for param field birth_address + attr_accessor :birth_address # The individual's date of birth. attr_accessor :dob # The individual's email address. @@ -575,6 +608,7 @@ def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, @@ -601,6 +635,7 @@ def initialize( @address = address @address_kana = address_kana @address_kanji = address_kanji + @birth_address = birth_address @dob = dob @email = email @first_name = first_name @@ -882,6 +917,37 @@ def initialize( end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + attr_accessor :city + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + attr_accessor :country + # Address line 1, such as the street, PO Box, or company name. + attr_accessor :line1 + # Address line 2, such as the apartment, suite, unit, or building. + attr_accessor :line2 + # ZIP or postal code. + attr_accessor :postal_code + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + attr_accessor :state + + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ) + @city = city + @country = country + @line1 = line1 + @line2 = line2 + @postal_code = postal_code + @state = state + end + end + class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. attr_accessor :day @@ -1112,6 +1178,8 @@ def initialize(additional_document: nil, document: nil) attr_accessor :address_kana # The Kanji variation of the person's address (Japan only). attr_accessor :address_kanji + # The person's place of birth. + attr_accessor :birth_address # The person's date of birth. attr_accessor :dob # Documents that may be submitted to satisfy various informational requests. @@ -1168,6 +1236,7 @@ def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, @@ -1198,6 +1267,7 @@ def initialize( @address = address @address_kana = address_kana @address_kanji = address_kanji + @birth_address = birth_address @dob = dob @documents = documents @email = email diff --git a/lib/stripe/params/v2/billing/contract_activate_params.rb b/lib/stripe/params/v2/billing/contract_activate_params.rb new file mode 100644 index 000000000..7ef49cc5a --- /dev/null +++ b/lib/stripe/params/v2/billing/contract_activate_params.rb @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + class ContractActivateParams < ::Stripe::RequestParams + # Additional fields to include in the response. + attr_accessor :include + + def initialize(include: nil) + @include = include + end + end + end + end +end diff --git a/lib/stripe/params/v2/billing/contract_cancel_params.rb b/lib/stripe/params/v2/billing/contract_cancel_params.rb new file mode 100644 index 000000000..24b2aafee --- /dev/null +++ b/lib/stripe/params/v2/billing/contract_cancel_params.rb @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + class ContractCancelParams < ::Stripe::RequestParams + # Additional fields to include in the response. + attr_accessor :include + + def initialize(include: nil) + @include = include + end + end + end + end +end diff --git a/lib/stripe/params/v2/billing/contract_create_params.rb b/lib/stripe/params/v2/billing/contract_create_params.rb new file mode 100644 index 000000000..a04f4055d --- /dev/null +++ b/lib/stripe/params/v2/billing/contract_create_params.rb @@ -0,0 +1,831 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + class ContractCreateParams < ::Stripe::RequestParams + class BillingSettings < ::Stripe::RequestParams + class ContractBillingDetails < ::Stripe::RequestParams + class BillSettingsDetails < ::Stripe::RequestParams + class Calculation < ::Stripe::RequestParams + class Tax < ::Stripe::RequestParams + # The type of tax calculation. + attr_accessor :type + + def initialize(type: nil) + @type = type + end + end + # Tax calculation settings. + attr_accessor :tax + + def initialize(tax: nil) + @tax = tax + end + end + + class Invoice < ::Stripe::RequestParams + class TimeUntilDue < ::Stripe::RequestParams + # The interval unit. + attr_accessor :interval + # The number of intervals. + attr_accessor :interval_count + + def initialize(interval: nil, interval_count: nil) + @interval = interval + @interval_count = interval_count + end + end + # The number of time units before the invoice is past due. + attr_accessor :time_until_due + + def initialize(time_until_due: nil) + @time_until_due = time_until_due + end + end + # Calculation settings. + attr_accessor :calculation + # Invoice settings. + attr_accessor :invoice + + def initialize(calculation: nil, invoice: nil) + @calculation = calculation + @invoice = invoice + end + end + + class BillingProfileDetails < ::Stripe::RequestParams + # The customer who pays for the contract invoice. + attr_accessor :customer + # The default payment method for the contract. + attr_accessor :default_payment_method + + def initialize(customer: nil, default_payment_method: nil) + @customer = customer + @default_payment_method = default_payment_method + end + end + + class CollectionSettingsDetails < ::Stripe::RequestParams + # The collection method. + attr_accessor :collection_method + # The payment method configuration. + attr_accessor :payment_method_configuration + + def initialize(collection_method: nil, payment_method_configuration: nil) + @collection_method = collection_method + @payment_method_configuration = payment_method_configuration + end + end + # The bill settings details. + attr_accessor :bill_settings_details + # The billing profile details. + attr_accessor :billing_profile_details + # The collection settings details. + attr_accessor :collection_settings_details + + def initialize( + bill_settings_details: nil, + billing_profile_details: nil, + collection_settings_details: nil + ) + @bill_settings_details = bill_settings_details + @billing_profile_details = billing_profile_details + @collection_settings_details = collection_settings_details + end + end + # Billing settings details for the contract. + attr_accessor :contract_billing_details + + def initialize(contract_billing_details: nil) + @contract_billing_details = contract_billing_details + end + end + + class ContractLine < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + attr_accessor :timestamp + + def initialize(timestamp: nil) + @timestamp = timestamp + end + end + + class Override < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + attr_accessor :timestamp + + def initialize(timestamp: nil) + @timestamp = timestamp + end + end + + class ServiceAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class CreditGrant < ::Stripe::RequestParams + class Amount < ::Stripe::RequestParams + # The monetary amount of the credit grant. Required if `type` is `monetary`. + attr_accessor :monetary + # The type of the credit grant amount. + attr_accessor :type + + def initialize(monetary: nil, type: nil) + @monetary = monetary + @type = type + end + end + + class ApplicabilityConfig < ::Stripe::RequestParams + class Scope < ::Stripe::RequestParams + # The billable items to apply the credit grant to. + attr_accessor :billable_items + # The price type that credit grants can apply to. + attr_accessor :price_type + + def initialize(billable_items: nil, price_type: nil) + @billable_items = billable_items + @price_type = price_type + end + end + # The applicability scope of the credit grant. + attr_accessor :scope + + def initialize(scope: nil) + @scope = scope + end + end + + class ExpiryConfig < ::Stripe::RequestParams + # The type of the expiry configuration. + attr_accessor :type + + def initialize(type: nil) + @type = type + end + end + # The amount of the credit grant. + attr_accessor :amount + # Defines the scope where the credit grant is applicable. + attr_accessor :applicability_config + # The category of the credit grant. + attr_accessor :category + # The expiry configuration for the credit grant. + attr_accessor :expiry_config + # A descriptive name. + attr_accessor :name + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + attr_accessor :priority + + def initialize( + amount: nil, + applicability_config: nil, + category: nil, + expiry_config: nil, + name: nil, + priority: nil + ) + @amount = amount + @applicability_config = applicability_config + @category = category + @expiry_config = expiry_config + @name = name + @priority = priority + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + attr_accessor :credit_grant + # The interval for assessing service. + attr_accessor :service_interval + # The length of the interval for assessing service. + attr_accessor :service_interval_count + # The type of the service action. + attr_accessor :type + + def initialize( + credit_grant: nil, + service_interval: nil, + service_interval_count: nil, + type: nil + ) + @credit_grant = credit_grant + @service_interval = service_interval + @service_interval_count = service_interval_count + @type = type + end + end + + class Replace < ::Stripe::RequestParams + class CreditGrant < ::Stripe::RequestParams + class Amount < ::Stripe::RequestParams + # The monetary amount of the credit grant. Required if `type` is `monetary`. + attr_accessor :monetary + # The type of the credit grant amount. + attr_accessor :type + + def initialize(monetary: nil, type: nil) + @monetary = monetary + @type = type + end + end + + class ApplicabilityConfig < ::Stripe::RequestParams + class Scope < ::Stripe::RequestParams + # The billable items to apply the credit grant to. + attr_accessor :billable_items + # The price type that credit grants can apply to. + attr_accessor :price_type + + def initialize(billable_items: nil, price_type: nil) + @billable_items = billable_items + @price_type = price_type + end + end + # The applicability scope of the credit grant. + attr_accessor :scope + + def initialize(scope: nil) + @scope = scope + end + end + + class ExpiryConfig < ::Stripe::RequestParams + # The type of the expiry configuration. + attr_accessor :type + + def initialize(type: nil) + @type = type + end + end + # The amount of the credit grant. + attr_accessor :amount + # Defines the scope where the credit grant is applicable. + attr_accessor :applicability_config + # The category of the credit grant. + attr_accessor :category + # The expiry configuration for the credit grant. + attr_accessor :expiry_config + # A descriptive name. + attr_accessor :name + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + attr_accessor :priority + + def initialize( + amount: nil, + applicability_config: nil, + category: nil, + expiry_config: nil, + name: nil, + priority: nil + ) + @amount = amount + @applicability_config = applicability_config + @category = category + @expiry_config = expiry_config + @name = name + @priority = priority + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + attr_accessor :credit_grant + # The ID of the service action to replace. + attr_accessor :id + # The lookup key for the service action to replace. + attr_accessor :lookup_key + # The interval for assessing service. + attr_accessor :service_interval + # The length of the interval for assessing service. + attr_accessor :service_interval_count + # The type of the service action. + attr_accessor :type + + def initialize( + credit_grant: nil, + id: nil, + lookup_key: nil, + service_interval: nil, + service_interval_count: nil, + type: nil + ) + @credit_grant = credit_grant + @id = id + @lookup_key = lookup_key + @service_interval = service_interval + @service_interval_count = service_interval_count + @type = type + end + end + # Parameters for adding a new service action. + attr_accessor :add + # Parameters for replacing an existing service action. + attr_accessor :replace + # The type of service action override. + attr_accessor :type + + def initialize(add: nil, replace: nil, type: nil) + @add = add + @replace = replace + @type = type + end + end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + attr_accessor :timestamp + + def initialize(timestamp: nil) + @timestamp = timestamp + end + end + # Timestamp to indicate when the override ends. + attr_accessor :ends_at + # Service action override parameters. Required if `type` is `service_action`. + attr_accessor :service_action + # Timestamp to indicate when the override starts. + attr_accessor :starts_at + # The type of the override. + attr_accessor :type + + def initialize(ends_at: nil, service_action: nil, starts_at: nil, type: nil) + @ends_at = ends_at + @service_action = service_action + @starts_at = starts_at + @type = type + end + end + + class Pricing < ::Stripe::RequestParams; end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + attr_accessor :timestamp + + def initialize(timestamp: nil) + @timestamp = timestamp + end + end + # Timestamp to indicate when the contract line ends. + attr_accessor :ends_at + # Set of key-value pairs that you can attach to an object. + attr_accessor :metadata + # List of overrides. Later overrides in the list override earlier ones. + attr_accessor :overrides + # The pricing configuration for the contract line. + attr_accessor :pricing + # Timestamp to indicate when the contract line starts. + attr_accessor :starts_at + + def initialize(ends_at: nil, metadata: nil, overrides: nil, pricing: nil, starts_at: nil) + @ends_at = ends_at + @metadata = metadata + @overrides = overrides + @pricing = pricing + @starts_at = starts_at + end + end + + class LicenseQuantityAction < ::Stripe::RequestParams + class EffectiveAt < ::Stripe::RequestParams + # The timestamp for the effective at. + attr_accessor :timestamp + # The type of the effective at. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class Set < ::Stripe::RequestParams + # The quantity to set. + attr_accessor :quantity + + def initialize(quantity: nil) + @quantity = quantity + end + end + # The effective at for the license quantity action. + attr_accessor :effective_at + # The ID of the license pricing. + attr_accessor :license_pricing_id + # The lookup key for the license pricing. + attr_accessor :license_pricing_lookup_key + # The type of the license pricing. + attr_accessor :license_pricing_type + # The pricing line for the license quantity action. + attr_accessor :pricing_line + # The set quantity for the license quantity action. + attr_accessor :set + # The type of the license quantity action. + attr_accessor :type + + def initialize( + effective_at: nil, + license_pricing_id: nil, + license_pricing_lookup_key: nil, + license_pricing_type: nil, + pricing_line: nil, + set: nil, + type: nil + ) + @effective_at = effective_at + @license_pricing_id = license_pricing_id + @license_pricing_lookup_key = license_pricing_lookup_key + @license_pricing_type = license_pricing_type + @pricing_line = pricing_line + @set = set + @type = type + end + end + + class OneTimeFee < ::Stripe::RequestParams + class BillSchedule < ::Stripe::RequestParams + class BillAt < ::Stripe::RequestParams + # The datetime at which the entry should be billed. Required if `type` is `datetime`. + attr_accessor :timestamp + # The type of the bill_at. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + # When this entry should be billed. + attr_accessor :bill_at + # The amount to bill for this entry, in the smallest currency unit. + attr_accessor :value + + def initialize(bill_at: nil, value: nil) + @bill_at = bill_at + @value = value + end + + def self.field_encodings + @field_encodings = { value: :int64_string } + end + end + + class ProductDetails < ::Stripe::RequestParams + # The ID of the v1 Product. + attr_accessor :product + + def initialize(product: nil) + @product = product + end + end + # The bill schedule for the fee. Each entry produces an individual invoice item billed at `bill_at`. + attr_accessor :bill_schedule + # The type of billable item that this fee references. + attr_accessor :billable_item_type + # Details for a product billable target. Required when `billable_item_type` is `product`. + attr_accessor :product_details + + def initialize(bill_schedule: nil, billable_item_type: nil, product_details: nil) + @bill_schedule = bill_schedule + @billable_item_type = billable_item_type + @product_details = product_details + end + + def self.field_encodings + @field_encodings = { + bill_schedule: { + kind: :array, + element: { kind: :object, fields: { value: :int64_string } }, + }, + } + end + end + + class PricingLine < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. Required if `type` is `timestamp`. + attr_accessor :timestamp + # The type of the ends_at. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class Pricing < ::Stripe::RequestParams + class PriceDetails < ::Stripe::RequestParams + # The ID of the V1 price. + attr_accessor :price + # The quantity for the price. Only applicable for licensed prices. + attr_accessor :quantity + + def initialize(price: nil, quantity: nil) + @price = price + @quantity = quantity + end + end + # V1 price details. Required if `type` is `price`. + attr_accessor :price_details + # The type of pricing. + attr_accessor :type + + def initialize(price_details: nil, type: nil) + @price_details = price_details + @type = type + end + end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. Required if `type` is `timestamp`. + attr_accessor :timestamp + # The type of the starts_at. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + # When the pricing line ends. + attr_accessor :ends_at + # A user-provided lookup key to reference this pricing line. + attr_accessor :lookup_key + # Set of key-value pairs that you can attach to an object. + attr_accessor :metadata + # The pricing configuration for the pricing line. + attr_accessor :pricing + # When the pricing line starts. + attr_accessor :starts_at + + def initialize(ends_at: nil, lookup_key: nil, metadata: nil, pricing: nil, starts_at: nil) + @ends_at = ends_at + @lookup_key = lookup_key + @metadata = metadata + @pricing = pricing + @starts_at = starts_at + end + end + + class PricingOverride < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. Required if `type` is `timestamp`. + attr_accessor :timestamp + # The type of the ends_at. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class Multiplier < ::Stripe::RequestParams + class Criterion < ::Stripe::RequestParams + class MetadataCondition < ::Stripe::RequestParams + class AllOf < ::Stripe::RequestParams + # The metadata key. + attr_accessor :key + # The metadata value. + attr_accessor :value + + def initialize(key: nil, value: nil) + @key = key + @value = value + end + end + # All of these key-value conditions must match. + attr_accessor :all_of + + def initialize(all_of: nil) + @all_of = all_of + end + end + # Filter by billable item IDs. + attr_accessor :billable_item_ids + # Filter by billable item lookup keys. + attr_accessor :billable_item_lookup_keys + # Filter by billable item type. + attr_accessor :billable_item_types + # Filter by metadata conditions. + attr_accessor :metadata_conditions + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + attr_accessor :rate_card_ids + # Whether to include or exclude items matching these criteria. + attr_accessor :type + + def initialize( + billable_item_ids: nil, + billable_item_lookup_keys: nil, + billable_item_types: nil, + metadata_conditions: nil, + rate_card_ids: nil, + type: nil + ) + @billable_item_ids = billable_item_ids + @billable_item_lookup_keys = billable_item_lookup_keys + @billable_item_types = billable_item_types + @metadata_conditions = metadata_conditions + @rate_card_ids = rate_card_ids + @type = type + end + end + # Criteria determining which rates the multiplier applies to. + attr_accessor :criteria + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + attr_accessor :factor + + def initialize(criteria: nil, factor: nil) + @criteria = criteria + @factor = factor + end + end + + class OverwritePrice < ::Stripe::RequestParams + class Tier < ::Stripe::RequestParams + # Price for the entire tier, represented as a decimal string in minor currency units. + attr_accessor :flat_amount + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + attr_accessor :unit_amount + # Up to and including this quantity will be contained in the tier. + attr_accessor :up_to_decimal + # No upper bound to this tier. + attr_accessor :up_to_inf + + def initialize(flat_amount: nil, unit_amount: nil, up_to_decimal: nil, up_to_inf: nil) + @flat_amount = flat_amount + @unit_amount = unit_amount + @up_to_decimal = up_to_decimal + @up_to_inf = up_to_inf + end + + def self.field_encodings + @field_encodings = { up_to_decimal: :decimal_string } + end + end + # The ID of the V1 price to overwrite. + attr_accessor :price + # Defines whether the tiered price should be graduated or volume-based. + attr_accessor :tiering_mode + # Each element represents a pricing tier. + attr_accessor :tiers + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + attr_accessor :unit_amount + + def initialize(price: nil, tiering_mode: nil, tiers: nil, unit_amount: nil) + @price = price + @tiering_mode = tiering_mode + @tiers = tiers + @unit_amount = unit_amount + end + + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + } + end + end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. Required if `type` is `timestamp`. + attr_accessor :timestamp + # The type of the starts_at. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + # When the pricing override ends. + attr_accessor :ends_at + # A user-provided lookup key to reference this pricing override. + attr_accessor :lookup_key + # Parameters for a multiplier override. Required if `type` is `multiplier`. + attr_accessor :multiplier + # Parameters for an overwrite_price override. Required if `type` is `overwrite_price`. + attr_accessor :overwrite_price + # The priority of this override relative to others. Lower number = higher priority. + attr_accessor :priority + # When the pricing override starts. + attr_accessor :starts_at + # The type of pricing override. + attr_accessor :type + + def initialize( + ends_at: nil, + lookup_key: nil, + multiplier: nil, + overwrite_price: nil, + priority: nil, + starts_at: nil, + type: nil + ) + @ends_at = ends_at + @lookup_key = lookup_key + @multiplier = multiplier + @overwrite_price = overwrite_price + @priority = priority + @starts_at = starts_at + @type = type + end + + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + }, + }, + } + end + end + # The billing settings for the contract. + attr_accessor :billing_settings + # A list of contract lines to create with the contract. + attr_accessor :contract_lines + # A unique user-provided contract number e.g. C-2026-0001. + attr_accessor :contract_number + # Currency of the contract. + attr_accessor :currency + # Additional fields to include in the response. + attr_accessor :include + # A list of license quantity actions to create with the contract. + attr_accessor :license_quantity_actions + # Set of key-value pairs that you can attach to an object. + attr_accessor :metadata + # A list of one-time fees to create with the contract. Each fee is billed as individual invoice items per its bill_schedule. + attr_accessor :one_time_fees + # A list of pricing lines to create with the contract. + attr_accessor :pricing_lines + # A list of pricing overrides to create with the contract. + attr_accessor :pricing_overrides + + def initialize( + billing_settings: nil, + contract_lines: nil, + contract_number: nil, + currency: nil, + include: nil, + license_quantity_actions: nil, + metadata: nil, + one_time_fees: nil, + pricing_lines: nil, + pricing_overrides: nil + ) + @billing_settings = billing_settings + @contract_lines = contract_lines + @contract_number = contract_number + @currency = currency + @include = include + @license_quantity_actions = license_quantity_actions + @metadata = metadata + @one_time_fees = one_time_fees + @pricing_lines = pricing_lines + @pricing_overrides = pricing_overrides + end + + def self.field_encodings + @field_encodings = { + one_time_fees: { + kind: :array, + element: { + kind: :object, + fields: { + bill_schedule: { + kind: :array, + element: { kind: :object, fields: { value: :int64_string } }, + }, + }, + }, + }, + pricing_overrides: { + kind: :array, + element: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + }, + }, + }, + }, + }, + } + end + end + end + end +end diff --git a/lib/stripe/params/v2/billing/contract_list_params.rb b/lib/stripe/params/v2/billing/contract_list_params.rb new file mode 100644 index 000000000..c32d5b018 --- /dev/null +++ b/lib/stripe/params/v2/billing/contract_list_params.rb @@ -0,0 +1,20 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + class ContractListParams < ::Stripe::RequestParams + # Filter by customer ID. + attr_accessor :customer + # The limit for the number of results per page. + attr_accessor :limit + + def initialize(customer: nil, limit: nil) + @customer = customer + @limit = limit + end + end + end + end +end diff --git a/lib/stripe/params/v2/billing/contract_retrieve_params.rb b/lib/stripe/params/v2/billing/contract_retrieve_params.rb new file mode 100644 index 000000000..11243bf6a --- /dev/null +++ b/lib/stripe/params/v2/billing/contract_retrieve_params.rb @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + class ContractRetrieveParams < ::Stripe::RequestParams + # Additional fields to include in the response. + attr_accessor :include + + def initialize(include: nil) + @include = include + end + end + end + end +end diff --git a/lib/stripe/params/v2/billing/contract_update_params.rb b/lib/stripe/params/v2/billing/contract_update_params.rb new file mode 100644 index 000000000..2da5de5a5 --- /dev/null +++ b/lib/stripe/params/v2/billing/contract_update_params.rb @@ -0,0 +1,522 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + class ContractUpdateParams < ::Stripe::RequestParams + class LicenseQuantityAction < ::Stripe::RequestParams + class EffectiveAt < ::Stripe::RequestParams + # The timestamp for the effective at. + attr_accessor :timestamp + # The type of the effective at. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class Set < ::Stripe::RequestParams + # The quantity to set. + attr_accessor :quantity + + def initialize(quantity: nil) + @quantity = quantity + end + end + # The effective at for the license quantity action. + attr_accessor :effective_at + # The ID of the license pricing. + attr_accessor :license_pricing_id + # The lookup key for the license pricing. + attr_accessor :license_pricing_lookup_key + # The type of the license pricing. + attr_accessor :license_pricing_type + # The pricing line ID for the license quantity action. + attr_accessor :pricing_line + # The pricing line lookup key for the license quantity action. + attr_accessor :pricing_line_lookup_key + # The set quantity for the license quantity action. + attr_accessor :set + # The type of the license quantity action. + attr_accessor :type + + def initialize( + effective_at: nil, + license_pricing_id: nil, + license_pricing_lookup_key: nil, + license_pricing_type: nil, + pricing_line: nil, + pricing_line_lookup_key: nil, + set: nil, + type: nil + ) + @effective_at = effective_at + @license_pricing_id = license_pricing_id + @license_pricing_lookup_key = license_pricing_lookup_key + @license_pricing_type = license_pricing_type + @pricing_line = pricing_line + @pricing_line_lookup_key = pricing_line_lookup_key + @set = set + @type = type + end + end + + class PricingLineAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + attr_accessor :timestamp + # The type of end time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class Pricing < ::Stripe::RequestParams + class PriceDetails < ::Stripe::RequestParams + # The ID of the V1 price. + attr_accessor :price + # The quantity for the price. Only applicable for licensed prices. + attr_accessor :quantity + + def initialize(price: nil, quantity: nil) + @price = price + @quantity = quantity + end + end + # V1 price details. Required if `type` is `price`. + attr_accessor :price_details + # The type of pricing. + attr_accessor :type + + def initialize(price_details: nil, type: nil) + @price_details = price_details + @type = type + end + end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + attr_accessor :timestamp + # The type of start time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + # The end time for the pricing line. + attr_accessor :ends_at + # A lookup key for the pricing line. + attr_accessor :lookup_key + # Metadata for the pricing line. + attr_accessor :metadata + # The pricing configuration for the pricing line. + attr_accessor :pricing + # The start time for the pricing line. + attr_accessor :starts_at + + def initialize( + ends_at: nil, + lookup_key: nil, + metadata: nil, + pricing: nil, + starts_at: nil + ) + @ends_at = ends_at + @lookup_key = lookup_key + @metadata = metadata + @pricing = pricing + @starts_at = starts_at + end + end + + class Remove < ::Stripe::RequestParams + # The ID of the pricing line to remove. + attr_accessor :id + + def initialize(id: nil) + @id = id + end + end + + class Update < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + attr_accessor :timestamp + # The type of end time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + attr_accessor :timestamp + # The type of start time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + # The updated end time for the pricing line. + attr_accessor :ends_at + # The ID of the pricing line. + attr_accessor :id + # The updated start time for the pricing line. + attr_accessor :starts_at + + def initialize(ends_at: nil, id: nil, starts_at: nil) + @ends_at = ends_at + @id = id + @starts_at = starts_at + end + end + # Parameters for adding a pricing line. + attr_accessor :add + # Parameters for removing a pricing line. + attr_accessor :remove + # The type of pricing line action. + attr_accessor :type + # Parameters for updating a pricing line. + attr_accessor :update + + def initialize(add: nil, remove: nil, type: nil, update: nil) + @add = add + @remove = remove + @type = type + @update = update + end + end + + class PricingOverrideAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + attr_accessor :timestamp + # The type of end time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class Multiplier < ::Stripe::RequestParams + class Criterion < ::Stripe::RequestParams + class MetadataCondition < ::Stripe::RequestParams + class AllOf < ::Stripe::RequestParams + # The metadata key. + attr_accessor :key + # The metadata value. + attr_accessor :value + + def initialize(key: nil, value: nil) + @key = key + @value = value + end + end + # All of these key-value conditions must match. + attr_accessor :all_of + + def initialize(all_of: nil) + @all_of = all_of + end + end + # Filter by billable item IDs. + attr_accessor :billable_item_ids + # Filter by billable item lookup keys. + attr_accessor :billable_item_lookup_keys + # Filter by billable item type. + attr_accessor :billable_item_types + # Filter by metadata conditions. + attr_accessor :metadata_conditions + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + attr_accessor :rate_card_ids + # Whether to include or exclude items matching these criteria. + attr_accessor :type + + def initialize( + billable_item_ids: nil, + billable_item_lookup_keys: nil, + billable_item_types: nil, + metadata_conditions: nil, + rate_card_ids: nil, + type: nil + ) + @billable_item_ids = billable_item_ids + @billable_item_lookup_keys = billable_item_lookup_keys + @billable_item_types = billable_item_types + @metadata_conditions = metadata_conditions + @rate_card_ids = rate_card_ids + @type = type + end + end + # Criteria determining which rates the multiplier applies to. + attr_accessor :criteria + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + attr_accessor :factor + + def initialize(criteria: nil, factor: nil) + @criteria = criteria + @factor = factor + end + end + + class OverwritePrice < ::Stripe::RequestParams + class Tier < ::Stripe::RequestParams + # Price for the entire tier, represented as a decimal string in minor currency units. + attr_accessor :flat_amount + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + attr_accessor :unit_amount + # Up to and including this quantity will be contained in the tier. + attr_accessor :up_to_decimal + # No upper bound to this tier. + attr_accessor :up_to_inf + + def initialize( + flat_amount: nil, + unit_amount: nil, + up_to_decimal: nil, + up_to_inf: nil + ) + @flat_amount = flat_amount + @unit_amount = unit_amount + @up_to_decimal = up_to_decimal + @up_to_inf = up_to_inf + end + + def self.field_encodings + @field_encodings = { up_to_decimal: :decimal_string } + end + end + # The ID of the V1 price to overwrite. + attr_accessor :price + # Defines whether the tiered price should be graduated or volume-based. + attr_accessor :tiering_mode + # Each element represents a pricing tier. + attr_accessor :tiers + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + attr_accessor :unit_amount + + def initialize(price: nil, tiering_mode: nil, tiers: nil, unit_amount: nil) + @price = price + @tiering_mode = tiering_mode + @tiers = tiers + @unit_amount = unit_amount + end + + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + } + end + end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + attr_accessor :timestamp + # The type of start time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + # The end time for the pricing override. + attr_accessor :ends_at + # A lookup key for the pricing override. + attr_accessor :lookup_key + # A multiplier override to add. + attr_accessor :multiplier + # An overwrite price override to add. + attr_accessor :overwrite_price + # The priority for the pricing override. + attr_accessor :priority + # The start time for the pricing override. + attr_accessor :starts_at + # The type of pricing override to add. + attr_accessor :type + + def initialize( + ends_at: nil, + lookup_key: nil, + multiplier: nil, + overwrite_price: nil, + priority: nil, + starts_at: nil, + type: nil + ) + @ends_at = ends_at + @lookup_key = lookup_key + @multiplier = multiplier + @overwrite_price = overwrite_price + @priority = priority + @starts_at = starts_at + @type = type + end + + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + }, + }, + } + end + end + + class Remove < ::Stripe::RequestParams + # The ID of the pricing override to remove. + attr_accessor :id + + def initialize(id: nil) + @id = id + end + end + + class Update < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + attr_accessor :timestamp + # The type of end time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + attr_accessor :timestamp + # The type of start time to apply. + attr_accessor :type + + def initialize(timestamp: nil, type: nil) + @timestamp = timestamp + @type = type + end + end + # The updated end time for the pricing override. + attr_accessor :ends_at + # The ID of the pricing override. + attr_accessor :id + # The updated start time for the pricing override. + attr_accessor :starts_at + + def initialize(ends_at: nil, id: nil, starts_at: nil) + @ends_at = ends_at + @id = id + @starts_at = starts_at + end + end + # Parameters for adding a pricing override. + attr_accessor :add + # Parameters for removing a pricing override. + attr_accessor :remove + # The type of pricing override action. + attr_accessor :type + # Parameters for updating a pricing override. + attr_accessor :update + + def initialize(add: nil, remove: nil, type: nil, update: nil) + @add = add + @remove = remove + @type = type + @update = update + end + + def self.field_encodings + @field_encodings = { + add: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + }, + }, + }, + }, + } + end + end + # Additional fields to include in the response. + attr_accessor :include + # Schema-only: License quantity actions (implementation to follow). + attr_accessor :license_quantity_actions + # Pricing line actions to apply. + attr_accessor :pricing_line_actions + # Pricing override actions to apply. + attr_accessor :pricing_override_actions + + def initialize( + include: nil, + license_quantity_actions: nil, + pricing_line_actions: nil, + pricing_override_actions: nil + ) + @include = include + @license_quantity_actions = license_quantity_actions + @pricing_line_actions = pricing_line_actions + @pricing_override_actions = pricing_override_actions + end + + def self.field_encodings + @field_encodings = { + pricing_override_actions: { + kind: :array, + element: { + kind: :object, + fields: { + add: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + }, + }, + }, + }, + }, + }, + }, + } + end + end + end + end +end diff --git a/lib/stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params.rb b/lib/stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params.rb new file mode 100644 index 000000000..49ea4eb17 --- /dev/null +++ b/lib/stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params.rb @@ -0,0 +1,21 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + module Contracts + module LicensePricing + class QuantityChangeListQuantityChangesParams < ::Stripe::RequestParams + # The limit for the number of results per page. + attr_accessor :limit + + def initialize(limit: nil) + @limit = limit + end + end + end + end + end + end +end diff --git a/lib/stripe/params/v2/core/account_create_params.rb b/lib/stripe/params/v2/core/account_create_params.rb index acec0d702..08d065e20 100644 --- a/lib/stripe/params/v2/core/account_create_params.rb +++ b/lib/stripe/params/v2/core/account_create_params.rb @@ -1747,10 +1747,13 @@ class Responsibilities < ::Stripe::RequestParams attr_accessor :fees_collector # A value indicating who is responsible for losses when this Account can’t pay back negative balances from payments. attr_accessor :losses_collector + # A value indicating the party responsible for collecting requirements on this account. + attr_accessor :requirements_collector - def initialize(fees_collector: nil, losses_collector: nil) + def initialize(fees_collector: nil, losses_collector: nil, requirements_collector: nil) @fees_collector = fees_collector @losses_collector = losses_collector + @requirements_collector = requirements_collector end end # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). diff --git a/lib/stripe/params/v2/core/account_update_params.rb b/lib/stripe/params/v2/core/account_update_params.rb index 73148f6e0..d7e830a56 100644 --- a/lib/stripe/params/v2/core/account_update_params.rb +++ b/lib/stripe/params/v2/core/account_update_params.rb @@ -1779,10 +1779,13 @@ class Responsibilities < ::Stripe::RequestParams attr_accessor :fees_collector # A value indicating who is responsible for losses when this Account can’t pay back negative balances from payments. attr_accessor :losses_collector + # A value indicating the party responsible for collecting requirements on this account. + attr_accessor :requirements_collector - def initialize(fees_collector: nil, losses_collector: nil) + def initialize(fees_collector: nil, losses_collector: nil, requirements_collector: nil) @fees_collector = fees_collector @losses_collector = losses_collector + @requirements_collector = requirements_collector end end # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). diff --git a/lib/stripe/params/v2/data/reporting/query_run_retrieve_params.rb b/lib/stripe/params/v2/data/reporting/query_run_retrieve_params.rb index eb5ef56ba..3ef402fe8 100644 --- a/lib/stripe/params/v2/data/reporting/query_run_retrieve_params.rb +++ b/lib/stripe/params/v2/data/reporting/query_run_retrieve_params.rb @@ -5,7 +5,14 @@ module Stripe module V2 module Data module Reporting - class QueryRunRetrieveParams < ::Stripe::RequestParams; end + class QueryRunRetrieveParams < ::Stripe::RequestParams + # Any optional includes (see https://docs.stripe.com/api-includable-response-values). + attr_accessor :include + + def initialize(include: nil) + @include = include + end + end end end end diff --git a/lib/stripe/params/v2/money_management/outbound_payment_create_params.rb b/lib/stripe/params/v2/money_management/outbound_payment_create_params.rb index 2bc9e5a77..88cda9f27 100644 --- a/lib/stripe/params/v2/money_management/outbound_payment_create_params.rb +++ b/lib/stripe/params/v2/money_management/outbound_payment_create_params.rb @@ -94,7 +94,7 @@ def initialize(currency: nil, payout_method: nil, recipient: nil) attr_accessor :recipient_notification # The recipient verification id for this OutboundPayment. Only required for countries with regulatory mandates to verify recipient names before OutboundPayment creation. attr_accessor :recipient_verification - # The description that appears on the receiving end for an OutboundPayment (for example, on a bank statement). Must be between 3 and 22 characters long, and not contain profanity. + # The description that appears on the receiving end for an OutboundPayment (for example, on a bank statement). Must be between 3 and 22 characters long for most destinations (500 for FinancialAccount destinations), and not contain profanity. attr_accessor :statement_descriptor # To which payout method to send the OutboundPayment. attr_accessor :to diff --git a/lib/stripe/params/v2/money_management/outbound_transfer_create_params.rb b/lib/stripe/params/v2/money_management/outbound_transfer_create_params.rb index 7e33af985..804f0771b 100644 --- a/lib/stripe/params/v2/money_management/outbound_transfer_create_params.rb +++ b/lib/stripe/params/v2/money_management/outbound_transfer_create_params.rb @@ -55,7 +55,7 @@ def initialize(currency: nil, payout_method: nil) attr_accessor :metadata # The recipient verification id for this OutboundTransfer. Only required for countries with regulatory mandates to verify recipient names before OutboundTransfer creation. attr_accessor :recipient_verification - # The description that appears on the receiving end for an OutboundTransfer (for example, on a bank statement). Must be between 3 and 22 characters long, and not contain profanity. + # The description that appears on the receiving end for an OutboundTransfer (for example, on a bank statement). Must be between 3 and 22 characters long for most destinations (500 for FinancialAccount destinations), and not contain profanity. attr_accessor :statement_descriptor # To which payout method to send the OutboundTransfer. attr_accessor :to diff --git a/lib/stripe/params/v2/reporting/report_run_retrieve_params.rb b/lib/stripe/params/v2/reporting/report_run_retrieve_params.rb index 1f76c569b..911e47ad7 100644 --- a/lib/stripe/params/v2/reporting/report_run_retrieve_params.rb +++ b/lib/stripe/params/v2/reporting/report_run_retrieve_params.rb @@ -4,7 +4,14 @@ module Stripe module V2 module Reporting - class ReportRunRetrieveParams < ::Stripe::RequestParams; end + class ReportRunRetrieveParams < ::Stripe::RequestParams + # Any optional includes (see https://docs.stripe.com/api-includable-response-values). + attr_accessor :include + + def initialize(include: nil) + @include = include + end + end end end end diff --git a/lib/stripe/params/v2/signals/account_signal_list_params.rb b/lib/stripe/params/v2/signals/account_signal_list_params.rb new file mode 100644 index 000000000..008d0130e --- /dev/null +++ b/lib/stripe/params/v2/signals/account_signal_list_params.rb @@ -0,0 +1,35 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Signals + class AccountSignalListParams < ::Stripe::RequestParams + class AccountDetails < ::Stripe::RequestParams + # The v2 account ID of the account. + attr_accessor :account + # The v1 customer ID of the account, for users not yet migrated to v2/accounts. + attr_accessor :customer + + def initialize(account: nil, customer: nil) + @account = account + @customer = customer + end + end + # The account or customer to list signals for. Exactly one of account_details.account or + # account_details.customer must be provided. + attr_accessor :account_details + # Maximum number of results to return per page. Defaults to 20. + attr_accessor :limit + # Signal types to filter by. + attr_accessor :type + + def initialize(account_details: nil, limit: nil, type: nil) + @account_details = account_details + @limit = limit + @type = type + end + end + end + end +end diff --git a/lib/stripe/params/v2/signals/account_signal_retrieve_params.rb b/lib/stripe/params/v2/signals/account_signal_retrieve_params.rb new file mode 100644 index 000000000..d085f1a99 --- /dev/null +++ b/lib/stripe/params/v2/signals/account_signal_retrieve_params.rb @@ -0,0 +1,10 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Signals + class AccountSignalRetrieveParams < ::Stripe::RequestParams; end + end + end +end diff --git a/lib/stripe/resources.rb b/lib/stripe/resources.rb index 80169c5dd..b75c18723 100644 --- a/lib/stripe/resources.rb +++ b/lib/stripe/resources.rb @@ -141,6 +141,8 @@ module Climate end module DelegatedCheckout + autoload :Order, "stripe/resources/delegated_checkout/order" + autoload :OrderEvent, "stripe/resources/delegated_checkout/order_event" autoload :RequestedSession, "stripe/resources/delegated_checkout/requested_session" end @@ -1273,6 +1275,10 @@ module Events "stripe/events/v2_signals_account_signal_fraudulent_merchant_ready_event" autoload :V2SignalsAccountSignalFraudulentMerchantReadyEventNotification, "stripe/events/v2_signals_account_signal_fraudulent_merchant_ready_event" + autoload :V2SignalsAccountSignalMerchantDelinquencyReadyEvent, + "stripe/events/v2_signals_account_signal_merchant_delinquency_ready_event" + autoload :V2SignalsAccountSignalMerchantDelinquencyReadyEventNotification, + "stripe/events/v2_signals_account_signal_merchant_delinquency_ready_event" end module FinancialConnections @@ -1406,6 +1412,9 @@ module Billing autoload :CadenceSpendModifier, "stripe/resources/v2/billing/cadence_spend_modifier" autoload :CollectionSetting, "stripe/resources/v2/billing/collection_setting" autoload :CollectionSettingVersion, "stripe/resources/v2/billing/collection_setting_version" + autoload :Contract, "stripe/resources/v2/billing/contract" + autoload :ContractLicensePricingQuantityChange, + "stripe/resources/v2/billing/contract_license_pricing_quantity_change" autoload :CustomPricingUnit, "stripe/resources/v2/billing/custom_pricing_unit" autoload :Intent, "stripe/resources/v2/billing/intent" autoload :IntentAction, "stripe/resources/v2/billing/intent_action" @@ -1521,6 +1530,10 @@ module Reporting autoload :ReportRun, "stripe/resources/v2/reporting/report_run" end + module Signals + autoload :AccountSignal, "stripe/resources/v2/signals/account_signal" + end + module Tax autoload :ManualRule, "stripe/resources/v2/tax/manual_rule" end @@ -1581,6 +1594,8 @@ module Stripe stripe/resources/customer_balance_transaction stripe/resources/customer_cash_balance_transaction stripe/resources/customer_session + stripe/resources/delegated_checkout/order + stripe/resources/delegated_checkout/order_event stripe/resources/delegated_checkout/requested_session stripe/resources/discount stripe/resources/dispute @@ -1727,6 +1742,8 @@ module Stripe stripe/resources/v2/billing/cadence_spend_modifier stripe/resources/v2/billing/collection_setting stripe/resources/v2/billing/collection_setting_version + stripe/resources/v2/billing/contract + stripe/resources/v2/billing/contract_license_pricing_quantity_change stripe/resources/v2/billing/custom_pricing_unit stripe/resources/v2/billing/intent stripe/resources/v2/billing/intent_action @@ -1800,6 +1817,7 @@ module Stripe stripe/resources/v2/payments/settlement_allocation_intent_split stripe/resources/v2/reporting/report stripe/resources/v2/reporting/report_run + stripe/resources/v2/signals/account_signal stripe/resources/v2/tax/manual_rule stripe/resources/webhook_endpoint stripe/events/v1_account_application_authorized_event @@ -2208,6 +2226,7 @@ module Stripe stripe/events/v2_reporting_report_run_succeeded_event stripe/events/v2_reporting_report_run_updated_event stripe/events/v2_signals_account_signal_fraudulent_merchant_ready_event + stripe/events/v2_signals_account_signal_merchant_delinquency_ready_event ].freeze # rubocop:enable Metrics/CollectionLiteralLength end diff --git a/lib/stripe/resources/delegated_checkout/order.rb b/lib/stripe/resources/delegated_checkout/order.rb new file mode 100644 index 000000000..6976a546c --- /dev/null +++ b/lib/stripe/resources/delegated_checkout/order.rb @@ -0,0 +1,142 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module DelegatedCheckout + # An order represents the post-checkout lifecycle of a delegated checkout purchase. + class Order < APIResource + OBJECT_NAME = "delegated_checkout.order" + def self.object_name + "delegated_checkout.order" + end + + class LineItem < ::Stripe::StripeObject + class ProductDetails < ::Stripe::StripeObject + # The item description. + attr_reader :description + # The item images. + attr_reader :images + # The item title. + attr_reader :title + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Quantity < ::Stripe::StripeObject + # The current quantity. + attr_reader :current + # The ordered quantity. + attr_reader :ordered + # The shipped quantity. + attr_reader :shipped + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Totals < ::Stripe::StripeObject + # The base amount for the line item. + attr_reader :base_amount + # The discount amount for the line item. + attr_reader :discount + # The subtotal amount for the line item. + attr_reader :subtotal + # The tax amount for the line item. + attr_reader :tax + # The total amount for the line item. + attr_reader :total + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The order line item key. + attr_reader :key + # Attribute for field product_details + attr_reader :product_details + # Attribute for field quantity + attr_reader :quantity + # The SKU ID of the line item. + attr_reader :sku_id + # The totals for this line item. + attr_reader :totals + # The line item unit amount. + attr_reader :unit_amount + + def self.inner_class_types + @inner_class_types = { product_details: ProductDetails, quantity: Quantity, totals: Totals } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Totals < ::Stripe::StripeObject + # The discount amount for the order. + attr_reader :discount + # The fulfillment amount for the order. + attr_reader :fulfillment + # The subtotal amount for the order. + attr_reader :subtotal + # The tax amount for the order. + attr_reader :tax + # The total amount for the order. + attr_reader :total + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Time at which the object was created. Measured in seconds since the Unix epoch. + attr_reader :created + # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). + attr_reader :currency + # Unique identifier for the object. + attr_reader :id + # The latest order event for this order. + attr_reader :latest_order_event + # The line items in this order. + attr_reader :line_items + # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. + attr_reader :livemode + # String representing the object's type. Objects of the same type share the same value. + attr_reader :object + # The permalink URL for this order. + attr_reader :permalink_url + # The requested session associated with this order. + attr_reader :requested_session + # The seller reference for this order. + attr_reader :seller_reference + # The totals for this order. + attr_reader :totals + + def self.inner_class_types + @inner_class_types = { line_items: LineItem, totals: Totals } + end + + def self.field_remappings + @field_remappings = {} + end + end + end +end diff --git a/lib/stripe/resources/delegated_checkout/order_event.rb b/lib/stripe/resources/delegated_checkout/order_event.rb new file mode 100644 index 000000000..9e1b090fe --- /dev/null +++ b/lib/stripe/resources/delegated_checkout/order_event.rb @@ -0,0 +1,118 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module DelegatedCheckout + # An order event represents a change to a delegated checkout order. + class OrderEvent < APIResource + OBJECT_NAME = "delegated_checkout.order_event" + def self.object_name + "delegated_checkout.order_event" + end + + class Adjustment < ::Stripe::StripeObject + class LineItem < ::Stripe::StripeObject + # The line item key. + attr_reader :key + # The quantity associated with the order event. + attr_reader :quantity + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The amount associated with the adjustment. + attr_reader :amount + # The currency associated with the adjustment amount. + attr_reader :currency + # The description of the adjustment. + attr_reader :description + # The line items associated with the adjustment. + attr_reader :line_items + # The status of the adjustment. + attr_reader :status + # The type of adjustment. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { line_items: LineItem } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Fulfillment < ::Stripe::StripeObject + class LineItem < ::Stripe::StripeObject + # The line item key. + attr_reader :key + # The quantity associated with the order event. + attr_reader :quantity + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The carrier for the fulfillment. + attr_reader :carrier + # Time at which the fulfillment was delivered. Measured in seconds since the Unix epoch. + attr_reader :delivered_at + # The line items associated with the fulfillment. + attr_reader :line_items + # Time at which the fulfillment shipped. Measured in seconds since the Unix epoch. + attr_reader :shipped_at + # The status of the fulfillment. + attr_reader :status + # The tracking number for the fulfillment. + attr_reader :tracking_number + # The tracking URL for the fulfillment. + attr_reader :tracking_url + + def self.inner_class_types + @inner_class_types = { line_items: LineItem } + end + + def self.field_remappings + @field_remappings = {} + end + end + # The adjustment details for this order event. + attr_reader :adjustment + # Time at which the object was created. Measured in seconds since the Unix epoch. + attr_reader :created + # The fulfillment details for this order event. + attr_reader :fulfillment + # Unique identifier for the object. + attr_reader :id + # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. + attr_reader :livemode + # String representing the object's type. Objects of the same type share the same value. + attr_reader :object + # Time at which this event occurred. Measured in seconds since the Unix epoch. + attr_reader :occurred_at + # The delegated checkout order associated with this order event. + attr_reader :order + # The requested session associated with this order event. + attr_reader :requested_session + # The type of order event. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { adjustment: Adjustment, fulfillment: Fulfillment } + end + + def self.field_remappings + @field_remappings = {} + end + end + end +end diff --git a/lib/stripe/resources/delegated_checkout/requested_session.rb b/lib/stripe/resources/delegated_checkout/requested_session.rb index 9cd38c707..ebb2560a4 100644 --- a/lib/stripe/resources/delegated_checkout/requested_session.rb +++ b/lib/stripe/resources/delegated_checkout/requested_session.rb @@ -841,6 +841,26 @@ def self.expire(requested_session, params = {}, opts = {}) ) end + # Lists orders for a delegated checkout requested session. + def list_orders(params = {}, opts = {}) + request_stripe_object( + method: :get, + path: format("/v1/delegated_checkout/requested_sessions/%s/orders", { requested_session: CGI.escape(self["id"]) }), + params: params, + opts: opts + ) + end + + # Lists orders for a delegated checkout requested session. + def self.list_orders(requested_session, params = {}, opts = {}) + request_stripe_object( + method: :get, + path: format("/v1/delegated_checkout/requested_sessions/%s/orders", { requested_session: CGI.escape(requested_session) }), + params: params, + opts: opts + ) + end + # Updates a requested session def self.update(requested_session, params = {}, opts = {}) request_stripe_object( diff --git a/lib/stripe/resources/issuing/authorization.rb b/lib/stripe/resources/issuing/authorization.rb index 9a62f9825..4513f4170 100644 --- a/lib/stripe/resources/issuing/authorization.rb +++ b/lib/stripe/resources/issuing/authorization.rb @@ -537,6 +537,8 @@ def self.field_remappings class Visa < ::Stripe::StripeObject # A unique reference ID from the network to represent the card account number. attr_reader :card_reference_id + # Stripe's recommendation to the network for this token activation request, derived from the same risk signals used for the activation decision. + attr_reader :token_decision_recommendation # The network-unique identifier for the token. attr_reader :token_reference_id # The ID of the entity requesting tokenization. @@ -605,6 +607,10 @@ def self.field_remappings attr_reader :device_fingerprint # Attribute for field network_data attr_reader :network_data + # The decision made during token provisioning. + attr_reader :provisioning_decision + # The type of the token, indicating how it is used. + attr_reader :token_type def self.inner_class_types @inner_class_types = { network_data: NetworkData } diff --git a/lib/stripe/resources/issuing/token.rb b/lib/stripe/resources/issuing/token.rb index 9b1feb337..78f4f71d5 100644 --- a/lib/stripe/resources/issuing/token.rb +++ b/lib/stripe/resources/issuing/token.rb @@ -19,6 +19,8 @@ class Device < ::Stripe::StripeObject attr_reader :device_fingerprint # The IP address of the device at provisioning time. attr_reader :ip_address + # The ISO 639-1 language code of the device associated with the tokenization request. + attr_reader :language # The geographic latitude/longitude coordinates of the device at provisioning time. The format is [+-]decimal/[+-]decimal. attr_reader :location # The name of the device used for tokenization. @@ -59,6 +61,8 @@ def self.field_remappings class Visa < ::Stripe::StripeObject # A unique reference ID from Visa to represent the card account number. attr_reader :card_reference_id + # Stripe's recommendation to the network for this token activation request, derived from the same risk signals used for the activation decision. + attr_reader :token_decision_recommendation # The network-unique identifier for the token. attr_reader :token_reference_id # The ID of the entity requesting tokenization, specific to Visa. @@ -163,8 +167,12 @@ def self.field_remappings attr_reader :network_updated_at # String representing the object's type. Objects of the same type share the same value. attr_reader :object + # The decision made during token provisioning. + attr_reader :provisioning_decision # The usage state of the token. attr_reader :status + # The type of the token, indicating how it is used. + attr_reader :token_type # The digital wallet for this token, if one was used. attr_reader :wallet_provider diff --git a/lib/stripe/resources/payment_intent.rb b/lib/stripe/resources/payment_intent.rb index 1955382d8..402630a83 100644 --- a/lib/stripe/resources/payment_intent.rb +++ b/lib/stripe/resources/payment_intent.rb @@ -3580,6 +3580,8 @@ class Crypto < ::Stripe::StripeObject class DepositOptions < ::Stripe::StripeObject # The blockchain networks to support for deposits. Learn more about [supported networks and tokens](https://docs.stripe.com/payments/deposit-mode-stablecoin-payments#token-and-network-support). attr_reader :networks + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + attr_reader :static_address def self.inner_class_types @inner_class_types = {} diff --git a/lib/stripe/resources/payment_location.rb b/lib/stripe/resources/payment_location.rb index 65f173bed..ddb0f6c5a 100644 --- a/lib/stripe/resources/payment_location.rb +++ b/lib/stripe/resources/payment_location.rb @@ -92,7 +92,7 @@ def self.field_remappings attr_reader :address # Identification numbers associated with the location. attr_reader :business_registration - # The capability settings for the location. Only applicable for locations with requested Payment Location Capabilities. + # The capability settings for the location. Only applicable for locations with requested payment location capabilities. attr_reader :capability_settings # Always true for a deleted object attr_reader :deleted diff --git a/lib/stripe/resources/payment_location_capability.rb b/lib/stripe/resources/payment_location_capability.rb index 623b30f42..ac5fca627 100644 --- a/lib/stripe/resources/payment_location_capability.rb +++ b/lib/stripe/resources/payment_location_capability.rb @@ -2,7 +2,7 @@ # frozen_string_literal: true module Stripe - # A Payment Location Capability represents a capability for a Stripe account at a Payment Location. + # A `payment_location` capability represents a capability for a Stripe account at a payment location. class PaymentLocationCapability < APIResource extend Stripe::APIOperations::List include Stripe::APIOperations::Save @@ -44,26 +44,26 @@ def self.field_remappings @field_remappings = {} end end - # The account for which the capability enables functionality. + # The account that the capability enables functionality for. attr_reader :account # The identifier for the capability. attr_reader :capability # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. attr_reader :livemode - # The payment location for which the capability enables functionality. + # The payment location that the capability enables functionality for. attr_reader :location # String representing the object's type. Objects of the same type share the same value. attr_reader :object # Whether the capability has been requested. attr_reader :requested - # Time at which the capability was requested. Measured in seconds since the Unix epoch. + # Time when the capability was requested. Measured in seconds since the Unix epoch. attr_reader :requested_at # Attribute for field requirements attr_reader :requirements # The status of the capability. attr_reader :status - # Returns a list of PaymentLocationCapability objects associated with the location. + # List all payment location capabilities associated with the payment location. def self.list(params = {}, opts = {}) request_stripe_object( method: :get, @@ -73,7 +73,7 @@ def self.list(params = {}, opts = {}) ) end - # Updates a specified Payment Location Capability. Request or remove a payment location capability by updating its requested parameter. + # Updates a payment_location capability. Request or remove a payment_location capability by updating its requested parameter. def self.update(capability, params = {}, opts = {}) request_stripe_object( method: :post, diff --git a/lib/stripe/resources/person.rb b/lib/stripe/resources/person.rb index c414d6984..9cebfb11c 100644 --- a/lib/stripe/resources/person.rb +++ b/lib/stripe/resources/person.rb @@ -117,6 +117,29 @@ def self.field_remappings end end + class BirthAddress < ::Stripe::StripeObject + # City, district, suburb, town, or village. + attr_reader :city + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + attr_reader :country + # Address line 1, such as the street, PO Box, or company name. + attr_reader :line1 + # Address line 2, such as the apartment, suite, unit, or building. + attr_reader :line2 + # ZIP or postal code. + attr_reader :postal_code + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + attr_reader :state + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + class Dob < ::Stripe::StripeObject # The day of birth, between 1 and 31. attr_reader :day @@ -435,6 +458,8 @@ def self.field_remappings attr_reader :address_kana # The Kanji variation of the person's address (Japan only). attr_reader :address_kanji + # Attribute for field birth_address + attr_reader :birth_address # Time at which the object was created. Measured in seconds since the Unix epoch. attr_reader :created # Always true for a deleted object @@ -523,6 +548,7 @@ def self.inner_class_types address: Address, address_kana: AddressKana, address_kanji: AddressKanji, + birth_address: BirthAddress, dob: Dob, future_requirements: FutureRequirements, registered_address: RegisteredAddress, diff --git a/lib/stripe/resources/v2/billing/contract.rb b/lib/stripe/resources/v2/billing/contract.rb new file mode 100644 index 000000000..53ba4510f --- /dev/null +++ b/lib/stripe/resources/v2/billing/contract.rb @@ -0,0 +1,978 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + # Main Contract resource representing a comprehensive billing agreement + class Contract < APIResource + OBJECT_NAME = "v2.billing.contract" + def self.object_name + "v2.billing.contract" + end + + class BillingSettings < ::Stripe::StripeObject + class ContractBillingDetails < ::Stripe::StripeObject + class BillSettingsDetails < ::Stripe::StripeObject + class Calculation < ::Stripe::StripeObject + class Tax < ::Stripe::StripeObject + # The type of tax calculation. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Tax calculation settings. + attr_reader :tax + + def self.inner_class_types + @inner_class_types = { tax: Tax } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Invoice < ::Stripe::StripeObject + class TimeUntilDue < ::Stripe::StripeObject + # The interval unit. + attr_reader :interval + # The number of intervals. + attr_reader :interval_count + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The number of time units before the invoice is past due. + attr_reader :time_until_due + + def self.inner_class_types + @inner_class_types = { time_until_due: TimeUntilDue } + end + + def self.field_remappings + @field_remappings = {} + end + end + # Calculation settings. + attr_reader :calculation + # Invoice settings. + attr_reader :invoice + + def self.inner_class_types + @inner_class_types = { calculation: Calculation, invoice: Invoice } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class BillingProfileDetails < ::Stripe::StripeObject + # The customer who pays for the contract invoice. + attr_reader :customer + # The default payment method for the contract. + attr_reader :default_payment_method + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class CollectionSettingsDetails < ::Stripe::StripeObject + # The collection method. + attr_reader :collection_method + # The payment method configuration. + attr_reader :payment_method_configuration + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The bill settings details. + attr_reader :bill_settings_details + # The billing profile details. + attr_reader :billing_profile_details + # The collection settings details. + attr_reader :collection_settings_details + + def self.inner_class_types + @inner_class_types = { + bill_settings_details: BillSettingsDetails, + billing_profile_details: BillingProfileDetails, + collection_settings_details: CollectionSettingsDetails, + } + end + + def self.field_remappings + @field_remappings = {} + end + end + # Billing settings details for the contract. + attr_reader :contract_billing_details + + def self.inner_class_types + @inner_class_types = { contract_billing_details: ContractBillingDetails } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class ContractLineDetail < ::Stripe::StripeObject + class ContractLineValueDetails < ::Stripe::StripeObject + # Computed sum of all licensed fees. Represented as a decimal string in minor currency units. + attr_reader :total + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Override < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class ServiceAction < ::Stripe::StripeObject + class Add < ::Stripe::StripeObject + class CreditGrant < ::Stripe::StripeObject + class Amount < ::Stripe::StripeObject + # The monetary amount of the credit grant. Required if `type` is `monetary`. + attr_reader :monetary + # The type of the credit grant amount. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class ApplicabilityConfig < ::Stripe::StripeObject + class Scope < ::Stripe::StripeObject + # The billable items to apply the credit grant to. + attr_reader :billable_items + # The price type that credit grants can apply to. + attr_reader :price_type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The applicability scope of the credit grant. + attr_reader :scope + + def self.inner_class_types + @inner_class_types = { scope: Scope } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class ExpiryConfig < ::Stripe::StripeObject + # The type of the expiry configuration. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The amount of the credit grant. + attr_reader :amount + # Defines the scope where the credit grant is applicable. + attr_reader :applicability_config + # The category of the credit grant. + attr_reader :category + # The expiry configuration for the credit grant. + attr_reader :expiry_config + # A descriptive name. + attr_reader :name + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + attr_reader :priority + + def self.inner_class_types + @inner_class_types = { + amount: Amount, + applicability_config: ApplicabilityConfig, + expiry_config: ExpiryConfig, + } + end + + def self.field_remappings + @field_remappings = {} + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + attr_reader :credit_grant + # The interval for assessing service. + attr_reader :service_interval + # The length of the interval for assessing service. + attr_reader :service_interval_count + # The type of the service action. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { credit_grant: CreditGrant } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Replace < ::Stripe::StripeObject + class CreditGrant < ::Stripe::StripeObject + class Amount < ::Stripe::StripeObject + # The monetary amount of the credit grant. Required if `type` is `monetary`. + attr_reader :monetary + # The type of the credit grant amount. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class ApplicabilityConfig < ::Stripe::StripeObject + class Scope < ::Stripe::StripeObject + # The billable items to apply the credit grant to. + attr_reader :billable_items + # The price type that credit grants can apply to. + attr_reader :price_type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The applicability scope of the credit grant. + attr_reader :scope + + def self.inner_class_types + @inner_class_types = { scope: Scope } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class ExpiryConfig < ::Stripe::StripeObject + # The type of the expiry configuration. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The amount of the credit grant. + attr_reader :amount + # Defines the scope where the credit grant is applicable. + attr_reader :applicability_config + # The category of the credit grant. + attr_reader :category + # The expiry configuration for the credit grant. + attr_reader :expiry_config + # A descriptive name. + attr_reader :name + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + attr_reader :priority + + def self.inner_class_types + @inner_class_types = { + amount: Amount, + applicability_config: ApplicabilityConfig, + expiry_config: ExpiryConfig, + } + end + + def self.field_remappings + @field_remappings = {} + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + attr_reader :credit_grant + # The ID of the service action to replace. + attr_reader :id + # The lookup key for the service action to replace. + attr_reader :lookup_key + # The interval for assessing service. + attr_reader :service_interval + # The length of the interval for assessing service. + attr_reader :service_interval_count + # The type of the service action. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { credit_grant: CreditGrant } + end + + def self.field_remappings + @field_remappings = {} + end + end + # Parameters for adding a new service action. + attr_reader :add + # Parameters for replacing an existing service action. + attr_reader :replace + # The type of service action override. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { add: Add, replace: Replace } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Timestamp to indicate when the override ends. + attr_reader :ends_at + # Service action override details. + attr_reader :service_action + # Timestamp to indicate when the override starts. + attr_reader :starts_at + # The type of the override. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { + ends_at: EndsAt, + service_action: ServiceAction, + starts_at: StartsAt, + } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Pricing < ::Stripe::StripeObject + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The ID of the contract line. + attr_reader :contract_line + # The computed value details for the contract line. + attr_reader :contract_line_value_details + # Timestamp of when the object was created. + attr_reader :created + # Timestamp to indicate when the contract line ends. + attr_reader :ends_at + # Set of key-value pairs that you can attach to an object. + attr_reader :metadata + # List of overrides applied to the contract line. + attr_reader :overrides + # The pricing configuration for the contract line. + attr_reader :pricing + # Timestamp to indicate when the contract line starts. + attr_reader :starts_at + + def self.inner_class_types + @inner_class_types = { + contract_line_value_details: ContractLineValueDetails, + ends_at: EndsAt, + overrides: Override, + pricing: Pricing, + starts_at: StartsAt, + } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class ContractValueDetails < ::Stripe::StripeObject + # The total value represented as a decimal string in minor currency units. + attr_reader :total + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class LicenseQuantity < ::Stripe::StripeObject + # The ID of the license pricing. + attr_reader :license_pricing_id + # The type of the license pricing. + attr_reader :license_pricing_type + # The ID of the pricing line associated with this license quantity. + attr_reader :pricing_line + # The current quantity of the license. + attr_reader :quantity + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class OneTimeFee < ::Stripe::StripeObject + class BillSchedule < ::Stripe::StripeObject + class BillAt < ::Stripe::StripeObject + # The datetime at which the entry will be billed. Set when `type` is `datetime`. + attr_reader :timestamp + # The type of the bill_at. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # When this entry will be billed. + attr_reader :bill_at + # The amount to bill for this entry, in the smallest currency unit. + attr_reader :value + + def self.inner_class_types + @inner_class_types = { bill_at: BillAt } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { value: :int64_string } + end + end + + class ProductDetails < ::Stripe::StripeObject + # The ID of the v1 Product. + attr_reader :product + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # The resolved bill schedule for the fee. + attr_reader :bill_schedule + # The type of billable item that this fee references. + attr_reader :billable_item_type + # Details for a product billable target. Set when `billable_item_type` is `product`. + attr_reader :product_details + + def self.inner_class_types + @inner_class_types = { bill_schedule: BillSchedule, product_details: ProductDetails } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { + bill_schedule: { + kind: :array, + element: { kind: :object, fields: { value: :int64_string } }, + }, + } + end + end + + class PricingLine < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Pricing < ::Stripe::StripeObject + class PriceDetails < ::Stripe::StripeObject + # The ID of the V1 price. + attr_reader :price + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # V1 price details. Present when `type` is `price`. + attr_reader :price_details + # The type of pricing. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { price_details: PriceDetails } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Resolved timestamp when the pricing line ends. + attr_reader :ends_at + # The user-provided lookup key for the pricing line. + attr_reader :lookup_key + # Set of key-value pairs that you can attach to an object. + attr_reader :metadata + # The pricing configuration for the pricing line. + attr_reader :pricing + # The ID of the pricing line. + attr_reader :pricing_line + # Resolved timestamp when the pricing line starts. + attr_reader :starts_at + + def self.inner_class_types + @inner_class_types = { ends_at: EndsAt, pricing: Pricing, starts_at: StartsAt } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class PricingOverride < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Multiplier < ::Stripe::StripeObject + class Criterion < ::Stripe::StripeObject + class MetadataCondition < ::Stripe::StripeObject + class AllOf < ::Stripe::StripeObject + # The metadata key. + attr_reader :key + # The metadata value. + attr_reader :value + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # All of these key-value conditions must match. + attr_reader :all_of + + def self.inner_class_types + @inner_class_types = { all_of: AllOf } + end + + def self.field_remappings + @field_remappings = {} + end + end + # Filter by billable item IDs. + attr_reader :billable_item_ids + # Filter by billable item lookup keys. + attr_reader :billable_item_lookup_keys + # Filter by billable item type. + attr_reader :billable_item_types + # Filter by metadata conditions. + attr_reader :metadata_conditions + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + attr_reader :rate_card_ids + # Whether to include or exclude items matching these criteria. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { metadata_conditions: MetadataCondition } + end + + def self.field_remappings + @field_remappings = {} + end + end + # Criteria determining which rates the multiplier applies to. + attr_reader :criteria + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + attr_reader :factor + + def self.inner_class_types + @inner_class_types = { criteria: Criterion } + end + + def self.field_remappings + @field_remappings = {} + end + end + + class OverwritePrice < ::Stripe::StripeObject + class Tier < ::Stripe::StripeObject + # Price for the entire tier, represented as a decimal string in minor currency units. + attr_reader :flat_amount + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + attr_reader :unit_amount + # Up to and including this quantity will be contained in the tier. + attr_reader :up_to_decimal + # No upper bound to this tier. + attr_reader :up_to_inf + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { up_to_decimal: :decimal_string } + end + end + # The ID of the V1 price to overwrite. + attr_reader :price + # Defines whether the tiered price should be graduated or volume-based. + attr_reader :tiering_mode + # Each element represents a pricing tier. + attr_reader :tiers + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + attr_reader :unit_amount + + def self.inner_class_types + @inner_class_types = { tiers: Tier } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + } + end + end + + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + attr_reader :timestamp + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Resolved timestamp when the pricing override ends. + attr_reader :ends_at + # The user-provided lookup key for the pricing override. + attr_reader :lookup_key + # Details for a multiplier override. + attr_reader :multiplier + # Details for an overwrite_price override. + attr_reader :overwrite_price + # The ID of the pricing override. + attr_reader :pricing_override + # The priority of this override relative to others. Lower number = higher priority. + attr_reader :priority + # Resolved timestamp when the pricing override starts. + attr_reader :starts_at + # The type of pricing override. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { + ends_at: EndsAt, + multiplier: Multiplier, + overwrite_price: OverwritePrice, + starts_at: StartsAt, + } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + }, + }, + } + end + end + + class StatusDetails < ::Stripe::StripeObject + class Active < ::Stripe::StripeObject + # The timestamp when the contract was activated. + attr_reader :activated_at + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class Canceled < ::Stripe::StripeObject + # The timestamp when the contract was canceled. + attr_reader :canceled_at + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Details of the active contract status. + attr_reader :active + # Details of the canceled contract status. + attr_reader :canceled + + def self.inner_class_types + @inner_class_types = { active: Active, canceled: Canceled } + end + + def self.field_remappings + @field_remappings = {} + end + end + # The billing settings for the contract. + attr_reader :billing_settings + # The contract line details of the contract. Only populated when `contract_line_details` is passed in the `include` parameter. + attr_reader :contract_line_details + # A unique user-provided contract number e.g. C-2026-0001. + attr_reader :contract_number + # The computed total value of all contract lines. + attr_reader :contract_value_details + # Timestamp of when the object was created. + attr_reader :created + # The currency of the contract. + attr_reader :currency + # The ID of the customer associated with the contract. + attr_reader :customer + # The ID of the contract object. + attr_reader :id + # The license quantities of the contract. Only populated when `license_quantities` is passed in the `include` parameter. + attr_reader :license_quantities + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + attr_reader :livemode + # Set of key-value pairs that you can attach to an object. + attr_reader :metadata + # String representing the object's type. Objects of the same type share the same value of the object field. + attr_reader :object + # The one-time fees of the contract. Only populated when `one_time_fees` is passed in the `include` parameter. + attr_reader :one_time_fees + # The pricing lines of the contract. Only populated when `pricing_lines` is passed in the `include` parameter. + attr_reader :pricing_lines + # The pricing overrides of the contract. Only populated when `pricing_overrides` is passed in the `include` parameter. + attr_reader :pricing_overrides + # The current status of the contract. + attr_reader :status + # Information about the contract status transitions. + attr_reader :status_details + + def self.inner_class_types + @inner_class_types = { + billing_settings: BillingSettings, + contract_line_details: ContractLineDetail, + contract_value_details: ContractValueDetails, + license_quantities: LicenseQuantity, + one_time_fees: OneTimeFee, + pricing_lines: PricingLine, + pricing_overrides: PricingOverride, + status_details: StatusDetails, + } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { + one_time_fees: { + kind: :array, + element: { + kind: :object, + fields: { + bill_schedule: { + kind: :array, + element: { kind: :object, fields: { value: :int64_string } }, + }, + }, + }, + }, + pricing_overrides: { + kind: :array, + element: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: { kind: :object, fields: { up_to_decimal: :decimal_string } }, + }, + }, + }, + }, + }, + }, + } + end + end + end + end +end diff --git a/lib/stripe/resources/v2/billing/contract_license_pricing_quantity_change.rb b/lib/stripe/resources/v2/billing/contract_license_pricing_quantity_change.rb new file mode 100644 index 000000000..d3fe79ba1 --- /dev/null +++ b/lib/stripe/resources/v2/billing/contract_license_pricing_quantity_change.rb @@ -0,0 +1,43 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + # A license pricing quantity change object returned by ListContractLicenseQuantityChanges. + class ContractLicensePricingQuantityChange < APIResource + OBJECT_NAME = "v2.billing.contract_license_pricing_quantity_change" + def self.object_name + "v2.billing.contract_license_pricing_quantity_change" + end + + # The timestamp when this quantity change object was created. + attr_reader :created + # The timestamp when this quantity change takes effect. + attr_reader :effective_at + # The ID of the quantity change object. + attr_reader :id + # The ID of the license pricing. + attr_reader :license_pricing_id + # The type of the license pricing. + attr_reader :license_pricing_type + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + attr_reader :livemode + # String representing the object's type. Objects of the same type share the same value of the object field. + attr_reader :object + # The ID of the pricing line associated with this quantity change. + attr_reader :pricing_line + # The quantity at the effective time. + attr_reader :quantity + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + end + end +end diff --git a/lib/stripe/resources/v2/data/reporting/query_run.rb b/lib/stripe/resources/v2/data/reporting/query_run.rb index e897c3beb..0f8cdb108 100644 --- a/lib/stripe/resources/v2/data/reporting/query_run.rb +++ b/lib/stripe/resources/v2/data/reporting/query_run.rb @@ -29,15 +29,32 @@ def self.field_remappings @field_remappings = {} end end + + class Schema < ::Stripe::StripeObject + # The name of the column. + attr_reader :name + # The type of the column. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end # The content type of the file. attr_reader :content_type # A pre-signed URL that allows secure, time-limited access to download the file. attr_reader :download_url + # The columns of the schema. + attr_reader :schema # The total size of the file in bytes. attr_reader :size def self.inner_class_types - @inner_class_types = { download_url: DownloadUrl } + @inner_class_types = { download_url: DownloadUrl, schema: Schema } end def self.field_remappings diff --git a/lib/stripe/resources/v2/reporting/report_run.rb b/lib/stripe/resources/v2/reporting/report_run.rb index 5c28f7ead..e3dc4355a 100644 --- a/lib/stripe/resources/v2/reporting/report_run.rb +++ b/lib/stripe/resources/v2/reporting/report_run.rb @@ -29,15 +29,32 @@ def self.field_remappings @field_remappings = {} end end + + class Schema < ::Stripe::StripeObject + # The name of the column. + attr_reader :name + # The type of the column. + attr_reader :type + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end # The content type of the file. attr_reader :content_type # A pre-signed URL that allows secure, time-limited access to download the file. attr_reader :download_url + # The columns of the schema. + attr_reader :schema # The total size of the file in bytes. attr_reader :size def self.inner_class_types - @inner_class_types = { download_url: DownloadUrl } + @inner_class_types = { download_url: DownloadUrl, schema: Schema } end def self.field_remappings diff --git a/lib/stripe/resources/v2/signals/account_signal.rb b/lib/stripe/resources/v2/signals/account_signal.rb new file mode 100644 index 000000000..cd976dd31 --- /dev/null +++ b/lib/stripe/resources/v2/signals/account_signal.rb @@ -0,0 +1,144 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Signals + # An automatically evaluated signal on a v2 account. + class AccountSignal < APIResource + OBJECT_NAME = "v2.signals.account_signal" + def self.object_name + "v2.signals.account_signal" + end + + class AccountDetails < ::Stripe::StripeObject + # The v2 account ID of the account. + attr_reader :account + # The v1 customer ID of the account, for users not yet migrated to v2/accounts. + attr_reader :customer + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + + class FraudulentMerchant < ::Stripe::StripeObject + class Indicator < ::Stripe::StripeObject + # A brief explanation of how this indicator contributed to the fraudulent merchant probability. + attr_reader :explanation + # The effect this indicator had on the overall risk level. + attr_reader :impact + # The name of the specific indicator used in the risk assessment. + attr_reader :indicator + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Array of objects representing individual factors that contributed to the calculated probability. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes indicators. + attr_reader :indicators + # The probability of the merchant being fraudulent. Can be between 0.00 and 100.00. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes numeric scores. + attr_reader :probability + # Categorical assessment of the fraudulent merchant risk based on probability. + attr_reader :risk_level + + def self.inner_class_types + @inner_class_types = { indicators: Indicator } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { probability: :decimal_string } + end + end + + class MerchantDelinquency < ::Stripe::StripeObject + class Indicator < ::Stripe::StripeObject + # A brief explanation of how this indicator contributed to the delinquency probability. + attr_reader :explanation + # The effect this indicator had on the overall risk level. + attr_reader :impact + # The name of the specific indicator used in the risk assessment. + attr_reader :indicator + + def self.inner_class_types + @inner_class_types = {} + end + + def self.field_remappings + @field_remappings = {} + end + end + # Array of objects representing individual factors that contributed to the calculated probability of delinquency. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes indicators. + attr_reader :indicators + # The probability of delinquency. Can be between 0.00 and 100.00. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes numeric scores. + attr_reader :probability + # Categorical assessment of the delinquency risk based on probability. + attr_reader :risk_level + + def self.inner_class_types + @inner_class_types = { indicators: Indicator } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { probability: :decimal_string } + end + end + # The account or customer this signal is associated with. + attr_reader :account_details + # Timestamp at which the signal was created. + attr_reader :created + # Data for the fraudulent merchant signal. Present only when type is fraudulent_merchant. + attr_reader :fraudulent_merchant + # Unique identifier for the account signal. + attr_reader :id + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + attr_reader :livemode + # Data for the merchant delinquency signal. Present only when type is merchant_delinquency. + attr_reader :merchant_delinquency + # String representing the object's type. Objects of the same type share the same value of the object field. + attr_reader :object + # The type of signal. + attr_reader :type + + def self.inner_class_types + @inner_class_types = { + account_details: AccountDetails, + fraudulent_merchant: FraudulentMerchant, + merchant_delinquency: MerchantDelinquency, + } + end + + def self.field_remappings + @field_remappings = {} + end + + def self.field_encodings + @field_encodings = { + fraudulent_merchant: { kind: :object, fields: { probability: :decimal_string } }, + merchant_delinquency: { kind: :object, fields: { probability: :decimal_string } }, + } + end + end + end + end +end diff --git a/lib/stripe/services.rb b/lib/stripe/services.rb index aa61f5b4e..def371c22 100644 --- a/lib/stripe/services.rb +++ b/lib/stripe/services.rb @@ -162,6 +162,8 @@ module Climate end module DelegatedCheckout + autoload :OrderService, "stripe/services/delegated_checkout/order_service" + autoload :RequestedSessionOrderService, "stripe/services/delegated_checkout/requested_session_order_service" autoload :RequestedSessionService, "stripe/services/delegated_checkout/requested_session_service" end @@ -334,8 +336,9 @@ module V2 autoload :MoneyManagementService, "stripe/services/v2/money_management_service" autoload :NetworkService, "stripe/services/v2/network_service" autoload :OrchestratedCommerceService, "stripe/services/v2/orchestrated_commerce_service" - autoload :PaymentService, "stripe/services/v2/payment_service" + autoload :PaymentsService, "stripe/services/v2/payments_service" autoload :ReportingService, "stripe/services/v2/reporting_service" + autoload :SignalsService, "stripe/services/v2/signals_service" autoload :TaxService, "stripe/services/v2/tax_service" autoload :TestHelperService, "stripe/services/v2/test_helper_service" @@ -343,6 +346,7 @@ module Billing autoload :BillSettingService, "stripe/services/v2/billing/bill_setting_service" autoload :CadenceService, "stripe/services/v2/billing/cadence_service" autoload :CollectionSettingService, "stripe/services/v2/billing/collection_setting_service" + autoload :ContractService, "stripe/services/v2/billing/contract_service" autoload :CustomPricingUnitService, "stripe/services/v2/billing/custom_pricing_unit_service" autoload :IntentService, "stripe/services/v2/billing/intent_service" autoload :LicensedItemService, "stripe/services/v2/billing/licensed_item_service" @@ -372,6 +376,15 @@ module CollectionSettings autoload :VersionService, "stripe/services/v2/billing/collection_settings/version_service" end + module Contracts + autoload :LicensePricingService, "stripe/services/v2/billing/contracts/license_pricing_service" + + module LicensePricing + autoload :QuantityChangeService, + "stripe/services/v2/billing/contracts/license_pricing/quantity_change_service" + end + end + module Intents autoload :ActionService, "stripe/services/v2/billing/intents/action_service" end @@ -497,6 +510,10 @@ module Reporting autoload :ReportService, "stripe/services/v2/reporting/report_service" end + module Signals + autoload :AccountSignalService, "stripe/services/v2/signals/account_signal_service" + end + module Tax autoload :ManualRuleService, "stripe/services/v2/tax/manual_rule_service" end @@ -570,6 +587,8 @@ module Stripe stripe/services/customer_service stripe/services/customer_session_service stripe/services/customer_tax_id_service + stripe/services/delegated_checkout/order_service + stripe/services/delegated_checkout/requested_session_order_service stripe/services/delegated_checkout/requested_session_service stripe/services/delegated_checkout_service stripe/services/dispute_service @@ -746,6 +765,9 @@ module Stripe stripe/services/v2/billing/cadences/spend_modifier_rule_service stripe/services/v2/billing/collection_setting_service stripe/services/v2/billing/collection_settings/version_service + stripe/services/v2/billing/contract_service + stripe/services/v2/billing/contracts/license_pricing/quantity_change_service + stripe/services/v2/billing/contracts/license_pricing_service stripe/services/v2/billing/custom_pricing_unit_service stripe/services/v2/billing/intent_service stripe/services/v2/billing/intents/action_service @@ -825,13 +847,15 @@ module Stripe stripe/services/v2/network_service stripe/services/v2/orchestrated_commerce/agreement_service stripe/services/v2/orchestrated_commerce_service - stripe/services/v2/payment_service stripe/services/v2/payments/off_session_payment_service stripe/services/v2/payments/settlement_allocation_intent_service stripe/services/v2/payments/settlement_allocation_intents/split_service + stripe/services/v2/payments_service stripe/services/v2/reporting/report_run_service stripe/services/v2/reporting/report_service stripe/services/v2/reporting_service + stripe/services/v2/signals/account_signal_service + stripe/services/v2/signals_service stripe/services/v2/tax/manual_rule_service stripe/services/v2/tax_service stripe/services/v2/test_helper_service diff --git a/lib/stripe/services/delegated_checkout/order_service.rb b/lib/stripe/services/delegated_checkout/order_service.rb new file mode 100644 index 000000000..bc5005e05 --- /dev/null +++ b/lib/stripe/services/delegated_checkout/order_service.rb @@ -0,0 +1,19 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module DelegatedCheckout + class OrderService < StripeService + # Retrieves a delegated checkout order. + def retrieve(order_id, params = {}, opts = {}) + request( + method: :get, + path: format("/v1/delegated_checkout/orders/%s", { order_id: CGI.escape(order_id) }), + params: params, + opts: opts, + base_address: :api + ) + end + end + end +end diff --git a/lib/stripe/services/delegated_checkout/requested_session_order_service.rb b/lib/stripe/services/delegated_checkout/requested_session_order_service.rb new file mode 100644 index 000000000..5bd15b780 --- /dev/null +++ b/lib/stripe/services/delegated_checkout/requested_session_order_service.rb @@ -0,0 +1,19 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module DelegatedCheckout + class RequestedSessionOrderService < StripeService + # Lists orders for a delegated checkout requested session. + def list(requested_session, params = {}, opts = {}) + request( + method: :get, + path: format("/v1/delegated_checkout/requested_sessions/%s/orders", { requested_session: CGI.escape(requested_session) }), + params: params, + opts: opts, + base_address: :api + ) + end + end + end +end diff --git a/lib/stripe/services/delegated_checkout/requested_session_service.rb b/lib/stripe/services/delegated_checkout/requested_session_service.rb index b6f0b43b8..13dff97ed 100644 --- a/lib/stripe/services/delegated_checkout/requested_session_service.rb +++ b/lib/stripe/services/delegated_checkout/requested_session_service.rb @@ -4,6 +4,13 @@ module Stripe module DelegatedCheckout class RequestedSessionService < StripeService + attr_reader :orders + + def initialize(requestor) + super + @orders = Stripe::DelegatedCheckout::RequestedSessionOrderService.new(@requestor) + end + # Confirms a requested session def confirm(requested_session, params = {}, opts = {}) request( diff --git a/lib/stripe/services/delegated_checkout_service.rb b/lib/stripe/services/delegated_checkout_service.rb index bba8c1666..ffc443479 100644 --- a/lib/stripe/services/delegated_checkout_service.rb +++ b/lib/stripe/services/delegated_checkout_service.rb @@ -3,10 +3,11 @@ module Stripe class DelegatedCheckoutService < StripeService - attr_reader :requested_sessions + attr_reader :orders, :requested_sessions def initialize(requestor) super + @orders = Stripe::DelegatedCheckout::OrderService.new(@requestor) @requested_sessions = Stripe::DelegatedCheckout::RequestedSessionService.new(@requestor) end end diff --git a/lib/stripe/services/payment_location_capability_service.rb b/lib/stripe/services/payment_location_capability_service.rb index 2969044f8..7053b6184 100644 --- a/lib/stripe/services/payment_location_capability_service.rb +++ b/lib/stripe/services/payment_location_capability_service.rb @@ -3,7 +3,7 @@ module Stripe class PaymentLocationCapabilityService < StripeService - # Returns a list of PaymentLocationCapability objects associated with the location. + # List all payment location capabilities associated with the payment location. def list(params = {}, opts = {}) request( method: :get, @@ -14,7 +14,7 @@ def list(params = {}, opts = {}) ) end - # Retrieves information about the specified Payment Location Capability. + # Retrieves a payment_location capability def retrieve(capability, params = {}, opts = {}) request( method: :get, @@ -25,7 +25,7 @@ def retrieve(capability, params = {}, opts = {}) ) end - # Updates a specified Payment Location Capability. Request or remove a payment location capability by updating its requested parameter. + # Updates a payment_location capability. Request or remove a payment_location capability by updating its requested parameter. def update(capability, params = {}, opts = {}) request( method: :post, diff --git a/lib/stripe/services/v2/billing/contract_service.rb b/lib/stripe/services/v2/billing/contract_service.rb new file mode 100644 index 000000000..0ee98539d --- /dev/null +++ b/lib/stripe/services/v2/billing/contract_service.rb @@ -0,0 +1,91 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + class ContractService < StripeService + attr_reader :license_pricing + + def initialize(requestor) + super + @license_pricing = Stripe::V2::Billing::Contracts::LicensePricingService.new(@requestor) + end + + # Activate a Draft Contract object by ID. + def activate(id, params = {}, opts = {}) + request( + method: :post, + path: format("/v2/billing/contracts/%s/activate", { id: CGI.escape(id) }), + params: params, + opts: opts, + base_address: :api + ) + end + + # Cancel a Contract object by ID. + def cancel(id, params = {}, opts = {}) + request( + method: :post, + path: format("/v2/billing/contracts/%s/cancel", { id: CGI.escape(id) }), + params: params, + opts: opts, + base_address: :api + ) + end + + # Create a Contract object. + def create(params = {}, opts = {}) + unless params.is_a?(Stripe::RequestParams) + params = ::Stripe::V2::Billing::ContractCreateParams.coerce_params(params) + end + + request( + method: :post, + path: "/v2/billing/contracts", + params: params, + opts: opts, + base_address: :api + ) + end + + # List Contract objects with pagination. + def list(params = {}, opts = {}) + request( + method: :get, + path: "/v2/billing/contracts", + params: params, + opts: opts, + base_address: :api + ) + end + + # Retrieve a Contract object by ID. + def retrieve(id, params = {}, opts = {}) + request( + method: :get, + path: format("/v2/billing/contracts/%s", { id: CGI.escape(id) }), + params: params, + opts: opts, + base_address: :api + ) + end + + # Update a Contract object by ID. + def update(id, params = {}, opts = {}) + unless params.is_a?(Stripe::RequestParams) + params = ::Stripe::V2::Billing::ContractUpdateParams.coerce_params(params) + end + + request( + method: :post, + path: format("/v2/billing/contracts/%s", { id: CGI.escape(id) }), + params: params, + opts: opts, + base_address: :api + ) + end + end + end + end +end diff --git a/lib/stripe/services/v2/billing/contracts/license_pricing/quantity_change_service.rb b/lib/stripe/services/v2/billing/contracts/license_pricing/quantity_change_service.rb new file mode 100644 index 000000000..8d6b3b118 --- /dev/null +++ b/lib/stripe/services/v2/billing/contracts/license_pricing/quantity_change_service.rb @@ -0,0 +1,25 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + module Contracts + module LicensePricing + class QuantityChangeService < StripeService + # List license quantity changes for a contract given a license pricing ID. + def list_quantity_changes(contract_id, license_pricing_id, params = {}, opts = {}) + request( + method: :get, + path: format("/v2/billing/contracts/%s/license_pricing/%s/quantity_changes", { contract_id: CGI.escape(contract_id), license_pricing_id: CGI.escape(license_pricing_id) }), + params: params, + opts: opts, + base_address: :api + ) + end + end + end + end + end + end +end diff --git a/lib/stripe/services/v2/billing/contracts/license_pricing_service.rb b/lib/stripe/services/v2/billing/contracts/license_pricing_service.rb new file mode 100644 index 000000000..48a518d04 --- /dev/null +++ b/lib/stripe/services/v2/billing/contracts/license_pricing_service.rb @@ -0,0 +1,20 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Billing + module Contracts + class LicensePricingService < StripeService + attr_reader :quantity_changes + + def initialize(requestor) + super + @quantity_changes = Stripe::V2::Billing::Contracts::LicensePricing::QuantityChangeService + .new(@requestor) + end + end + end + end + end +end diff --git a/lib/stripe/services/v2/billing_service.rb b/lib/stripe/services/v2/billing_service.rb index dfa4662a7..fb80923cb 100644 --- a/lib/stripe/services/v2/billing_service.rb +++ b/lib/stripe/services/v2/billing_service.rb @@ -4,13 +4,14 @@ module Stripe module V2 class BillingService < StripeService - attr_reader :bill_settings, :cadences, :collection_settings, :custom_pricing_units, :intents, :license_fees, :licensed_items, :meter_events, :meter_event_adjustments, :meter_event_session, :meter_event_stream, :metered_items, :one_time_items, :pricing_plans, :pricing_plan_subscriptions, :profiles, :rate_cards, :rate_card_subscriptions, :service_actions + attr_reader :bill_settings, :cadences, :collection_settings, :contracts, :custom_pricing_units, :intents, :license_fees, :licensed_items, :meter_events, :meter_event_adjustments, :meter_event_session, :meter_event_stream, :metered_items, :one_time_items, :pricing_plans, :pricing_plan_subscriptions, :profiles, :rate_cards, :rate_card_subscriptions, :service_actions def initialize(requestor) super @bill_settings = Stripe::V2::Billing::BillSettingService.new(@requestor) @cadences = Stripe::V2::Billing::CadenceService.new(@requestor) @collection_settings = Stripe::V2::Billing::CollectionSettingService.new(@requestor) + @contracts = Stripe::V2::Billing::ContractService.new(@requestor) @custom_pricing_units = Stripe::V2::Billing::CustomPricingUnitService.new(@requestor) @intents = Stripe::V2::Billing::IntentService.new(@requestor) @license_fees = Stripe::V2::Billing::LicenseFeeService.new(@requestor) diff --git a/lib/stripe/services/v2/payment_service.rb b/lib/stripe/services/v2/payments_service.rb similarity index 92% rename from lib/stripe/services/v2/payment_service.rb rename to lib/stripe/services/v2/payments_service.rb index ce1036fb3..062f7a7f2 100644 --- a/lib/stripe/services/v2/payment_service.rb +++ b/lib/stripe/services/v2/payments_service.rb @@ -3,7 +3,7 @@ module Stripe module V2 - class PaymentService < StripeService + class PaymentsService < StripeService attr_reader :off_session_payments, :settlement_allocation_intents def initialize(requestor) diff --git a/lib/stripe/services/v2/signals/account_signal_service.rb b/lib/stripe/services/v2/signals/account_signal_service.rb new file mode 100644 index 000000000..27833a2ef --- /dev/null +++ b/lib/stripe/services/v2/signals/account_signal_service.rb @@ -0,0 +1,32 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + module Signals + class AccountSignalService < StripeService + # Lists AccountSignals for a given account or customer, filtered by signal type. + def list(params = {}, opts = {}) + request( + method: :get, + path: "/v2/signals/account_signals", + params: params, + opts: opts, + base_address: :api + ) + end + + # Retrieves an AccountSignal by its ID. + def retrieve(id, params = {}, opts = {}) + request( + method: :get, + path: format("/v2/signals/account_signals/%s", { id: CGI.escape(id) }), + params: params, + opts: opts, + base_address: :api + ) + end + end + end + end +end diff --git a/lib/stripe/services/v2/signals_service.rb b/lib/stripe/services/v2/signals_service.rb new file mode 100644 index 000000000..35123341e --- /dev/null +++ b/lib/stripe/services/v2/signals_service.rb @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +module Stripe + module V2 + class SignalsService < StripeService + attr_reader :account_signals + + def initialize(requestor) + super + @account_signals = Stripe::V2::Signals::AccountSignalService.new(@requestor) + end + end + end +end diff --git a/lib/stripe/services/v2_services.rb b/lib/stripe/services/v2_services.rb index 404a4e288..c3b7351a5 100644 --- a/lib/stripe/services/v2_services.rb +++ b/lib/stripe/services/v2_services.rb @@ -3,7 +3,7 @@ module Stripe class V2Services < StripeService - attr_reader :billing, :commerce, :core, :data, :extend, :iam, :money_management, :network, :orchestrated_commerce, :payments, :reporting, :tax, :test_helpers + attr_reader :billing, :commerce, :core, :data, :extend, :iam, :money_management, :network, :orchestrated_commerce, :payments, :reporting, :signals, :tax, :test_helpers def initialize(requestor) super @@ -16,8 +16,9 @@ def initialize(requestor) @money_management = Stripe::V2::MoneyManagementService.new(@requestor) @network = Stripe::V2::NetworkService.new(@requestor) @orchestrated_commerce = Stripe::V2::OrchestratedCommerceService.new(@requestor) - @payments = Stripe::V2::PaymentService.new(@requestor) + @payments = Stripe::V2::PaymentsService.new(@requestor) @reporting = Stripe::V2::ReportingService.new(@requestor) + @signals = Stripe::V2::SignalsService.new(@requestor) @tax = Stripe::V2::TaxService.new(@requestor) @test_helpers = Stripe::V2::TestHelperService.new(@requestor) end diff --git a/lib/stripe/stripe_event_notification_handler.rb b/lib/stripe/stripe_event_notification_handler.rb index 25acdd497..c06bbef6a 100644 --- a/lib/stripe/stripe_event_notification_handler.rb +++ b/lib/stripe/stripe_event_notification_handler.rb @@ -2509,6 +2509,12 @@ def on_v2_signals_account_signal_fraudulent_merchant_ready(&handler) register("v2.signals.account_signal.fraudulent_merchant_ready", &handler) end + + def on_v2_signals_account_signal_merchant_delinquency_ready(&handler) + raise ArgumentError, "Block required to register event handler" if handler.nil? + + register("v2.signals.account_signal.merchant_delinquency_ready", &handler) + end # event-handler-methods: The end of the section generated from our OpenAPI spec end end diff --git a/rbi/stripe.rbi b/rbi/stripe.rbi index 31ede91e1..282dd3749 100644 --- a/rbi/stripe.rbi +++ b/rbi/stripe.rbi @@ -697,6 +697,43 @@ module Stripe end end # typed: true +module Stripe + module V2 + module Billing + # A license pricing quantity change object returned by ListContractLicenseQuantityChanges. + class ContractLicensePricingQuantityChange < APIResource + # The timestamp when this quantity change object was created. + sig { returns(String) } + def created; end + # The timestamp when this quantity change takes effect. + sig { returns(String) } + def effective_at; end + # The ID of the quantity change object. + sig { returns(String) } + def id; end + # The ID of the license pricing. + sig { returns(String) } + def license_pricing_id; end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + sig { returns(T::Boolean) } + def livemode; end + # String representing the object's type. Objects of the same type share the same value of the object field. + sig { returns(String) } + def object; end + # The ID of the pricing line associated with this quantity change. + sig { returns(String) } + def pricing_line; end + # The quantity at the effective time. + sig { returns(Integer) } + def quantity; end + end + end + end +end +# typed: true module Stripe module V2 class DeletedObject < APIResource @@ -1982,6 +2019,127 @@ module Stripe end end # typed: true +module Stripe + module DelegatedCheckout + # An order event represents a change to a delegated checkout order. + class OrderEvent < APIResource + class Adjustment < ::Stripe::StripeObject + class LineItem < ::Stripe::StripeObject + # The line item key. + sig { returns(String) } + def key; end + # The quantity associated with the order event. + sig { returns(Integer) } + def quantity; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The amount associated with the adjustment. + sig { returns(T.nilable(Integer)) } + def amount; end + # The currency associated with the adjustment amount. + sig { returns(T.nilable(String)) } + def currency; end + # The description of the adjustment. + sig { returns(String) } + def description; end + # The line items associated with the adjustment. + sig { returns(T.nilable(T::Array[LineItem])) } + def line_items; end + # The status of the adjustment. + sig { returns(String) } + def status; end + # The type of adjustment. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {line_items: LineItem} + end + def self.field_remappings + @field_remappings = {} + end + end + class Fulfillment < ::Stripe::StripeObject + class LineItem < ::Stripe::StripeObject + # The line item key. + sig { returns(String) } + def key; end + # The quantity associated with the order event. + sig { returns(Integer) } + def quantity; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The carrier for the fulfillment. + sig { returns(T.nilable(String)) } + def carrier; end + # Time at which the fulfillment was delivered. Measured in seconds since the Unix epoch. + sig { returns(T.nilable(Integer)) } + def delivered_at; end + # The line items associated with the fulfillment. + sig { returns(T::Array[LineItem]) } + def line_items; end + # Time at which the fulfillment shipped. Measured in seconds since the Unix epoch. + sig { returns(T.nilable(Integer)) } + def shipped_at; end + # The status of the fulfillment. + sig { returns(String) } + def status; end + # The tracking number for the fulfillment. + sig { returns(T.nilable(String)) } + def tracking_number; end + # The tracking URL for the fulfillment. + sig { returns(T.nilable(String)) } + def tracking_url; end + def self.inner_class_types + @inner_class_types = {line_items: LineItem} + end + def self.field_remappings + @field_remappings = {} + end + end + # The adjustment details for this order event. + sig { returns(T.nilable(Adjustment)) } + def adjustment; end + # Time at which the object was created. Measured in seconds since the Unix epoch. + sig { returns(Integer) } + def created; end + # The fulfillment details for this order event. + sig { returns(T.nilable(Fulfillment)) } + def fulfillment; end + # Unique identifier for the object. + sig { returns(String) } + def id; end + # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. + sig { returns(T::Boolean) } + def livemode; end + # String representing the object's type. Objects of the same type share the same value. + sig { returns(String) } + def object; end + # Time at which this event occurred. Measured in seconds since the Unix epoch. + sig { returns(Integer) } + def occurred_at; end + # The delegated checkout order associated with this order event. + sig { returns(String) } + def order; end + # The requested session associated with this order event. + sig { returns(String) } + def requested_session; end + # The type of order event. + sig { returns(String) } + def type; end + end + end +end +# typed: true module Stripe # PaymentMethodBalance objects represent balances available on a payment method. # You can use v1/payment_methods/:id/check_balance to check the balance of a payment method. @@ -6248,6 +6406,32 @@ module Stripe @field_remappings = {} end end + class BirthAddress < ::Stripe::StripeObject + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end class Dob < ::Stripe::StripeObject # The day of birth, between 1 and 31. sig { returns(T.nilable(Integer)) } @@ -6588,6 +6772,9 @@ module Stripe # The Kanji variation of the person's address (Japan only). sig { returns(T.nilable(AddressKanji)) } def address_kanji; end + # Attribute for field birth_address + sig { returns(T.nilable(BirthAddress)) } + def birth_address; end # Time at which the object was created. Measured in seconds since the Unix epoch. sig { returns(Integer) } def created; end @@ -20015,6 +20202,153 @@ module Stripe end end # typed: true +module Stripe + module DelegatedCheckout + # An order represents the post-checkout lifecycle of a delegated checkout purchase. + class Order < APIResource + class LineItem < ::Stripe::StripeObject + class ProductDetails < ::Stripe::StripeObject + # The item description. + sig { returns(T.nilable(String)) } + def description; end + # The item images. + sig { returns(T.nilable(T::Array[String])) } + def images; end + # The item title. + sig { returns(String) } + def title; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Quantity < ::Stripe::StripeObject + # The current quantity. + sig { returns(Integer) } + def current; end + # The ordered quantity. + sig { returns(Integer) } + def ordered; end + # The shipped quantity. + sig { returns(Integer) } + def shipped; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Totals < ::Stripe::StripeObject + # The base amount for the line item. + sig { returns(T.nilable(Integer)) } + def base_amount; end + # The discount amount for the line item. + sig { returns(T.nilable(Integer)) } + def discount; end + # The subtotal amount for the line item. + sig { returns(T.nilable(Integer)) } + def subtotal; end + # The tax amount for the line item. + sig { returns(T.nilable(Integer)) } + def tax; end + # The total amount for the line item. + sig { returns(T.nilable(Integer)) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The order line item key. + sig { returns(String) } + def key; end + # Attribute for field product_details + sig { returns(ProductDetails) } + def product_details; end + # Attribute for field quantity + sig { returns(Quantity) } + def quantity; end + # The SKU ID of the line item. + sig { returns(String) } + def sku_id; end + # The totals for this line item. + sig { returns(T.nilable(Totals)) } + def totals; end + # The line item unit amount. + sig { returns(Integer) } + def unit_amount; end + def self.inner_class_types + @inner_class_types = {product_details: ProductDetails, quantity: Quantity, totals: Totals} + end + def self.field_remappings + @field_remappings = {} + end + end + class Totals < ::Stripe::StripeObject + # The discount amount for the order. + sig { returns(T.nilable(Integer)) } + def discount; end + # The fulfillment amount for the order. + sig { returns(T.nilable(Integer)) } + def fulfillment; end + # The subtotal amount for the order. + sig { returns(T.nilable(Integer)) } + def subtotal; end + # The tax amount for the order. + sig { returns(T.nilable(Integer)) } + def tax; end + # The total amount for the order. + sig { returns(T.nilable(Integer)) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Time at which the object was created. Measured in seconds since the Unix epoch. + sig { returns(Integer) } + def created; end + # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). + sig { returns(String) } + def currency; end + # Unique identifier for the object. + sig { returns(String) } + def id; end + # The latest order event for this order. + sig { returns(T.nilable(::Stripe::DelegatedCheckout::OrderEvent)) } + def latest_order_event; end + # The line items in this order. + sig { returns(T::Array[LineItem]) } + def line_items; end + # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. + sig { returns(T::Boolean) } + def livemode; end + # String representing the object's type. Objects of the same type share the same value. + sig { returns(String) } + def object; end + # The permalink URL for this order. + sig { returns(T.nilable(String)) } + def permalink_url; end + # The requested session associated with this order. + sig { returns(String) } + def requested_session; end + # The seller reference for this order. + sig { returns(T.nilable(String)) } + def seller_reference; end + # The totals for this order. + sig { returns(T.nilable(Totals)) } + def totals; end + end + end +end +# typed: true module Stripe module DelegatedCheckout # A requested session is a session that has been requested by a customer. @@ -20895,6 +21229,18 @@ module Stripe } def self.expire(requested_session, params = {}, opts = {}); end + # Lists orders for a delegated checkout requested session. + sig { + params(params: T.any(::Stripe::DelegatedCheckout::RequestedSessionListOrdersParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) + } + def list_orders(params = {}, opts = {}); end + + # Lists orders for a delegated checkout requested session. + sig { + params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionListOrdersParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) + } + def self.list_orders(requested_session, params = {}, opts = {}); end + # Updates a requested session sig { params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::DelegatedCheckout::RequestedSession) @@ -27124,6 +27470,9 @@ module Stripe # A unique reference ID from the network to represent the card account number. sig { returns(T.nilable(String)) } def card_reference_id; end + # Stripe's recommendation to the network for this token activation request, derived from the same risk signals used for the activation decision. + sig { returns(T.nilable(String)) } + def token_decision_recommendation; end # The network-unique identifier for the token. sig { returns(String) } def token_reference_id; end @@ -27202,6 +27551,12 @@ module Stripe # Attribute for field network_data sig { returns(T.nilable(NetworkData)) } def network_data; end + # The decision made during token provisioning. + sig { returns(T.nilable(String)) } + def provisioning_decision; end + # The type of the token, indicating how it is used. + sig { returns(T.nilable(String)) } + def token_type; end def self.inner_class_types @inner_class_types = {network_data: NetworkData} end @@ -29142,6 +29497,9 @@ module Stripe # The IP address of the device at provisioning time. sig { returns(T.nilable(String)) } def ip_address; end + # The ISO 639-1 language code of the device associated with the tokenization request. + sig { returns(T.nilable(String)) } + def language; end # The geographic latitude/longitude coordinates of the device at provisioning time. The format is [+-]decimal/[+-]decimal. sig { returns(T.nilable(String)) } def location; end @@ -29185,6 +29543,9 @@ module Stripe # A unique reference ID from Visa to represent the card account number. sig { returns(T.nilable(String)) } def card_reference_id; end + # Stripe's recommendation to the network for this token activation request, derived from the same risk signals used for the activation decision. + sig { returns(T.nilable(String)) } + def token_decision_recommendation; end # The network-unique identifier for the token. sig { returns(String) } def token_reference_id; end @@ -29310,9 +29671,15 @@ module Stripe # String representing the object's type. Objects of the same type share the same value. sig { returns(String) } def object; end + # The decision made during token provisioning. + sig { returns(T.nilable(String)) } + def provisioning_decision; end # The usage state of the token. sig { returns(String) } def status; end + # The type of the token, indicating how it is used. + sig { returns(T.nilable(String)) } + def token_type; end # The digital wallet for this token, if one was used. sig { returns(T.nilable(String)) } def wallet_provider; end @@ -37741,6 +38108,9 @@ module Stripe # The blockchain networks to support for deposits. Learn more about [supported networks and tokens](https://docs.stripe.com/payments/deposit-mode-stablecoin-payments#token-and-network-support). sig { returns(T.nilable(T::Array[String])) } def networks; end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end def self.inner_class_types @inner_class_types = {} end @@ -40744,7 +41114,7 @@ module Stripe end # typed: true module Stripe - # A Payment Location Capability represents a capability for a Stripe account at a Payment Location. + # A `payment_location` capability represents a capability for a Stripe account at a payment location. class PaymentLocationCapability < APIResource class Requirements < ::Stripe::StripeObject class Error < ::Stripe::StripeObject @@ -40780,7 +41150,7 @@ module Stripe @field_remappings = {} end end - # The account for which the capability enables functionality. + # The account that the capability enables functionality for. sig { returns(String) } def account; end # The identifier for the capability. @@ -40789,7 +41159,7 @@ module Stripe # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. sig { returns(T::Boolean) } def livemode; end - # The payment location for which the capability enables functionality. + # The payment location that the capability enables functionality for. sig { returns(String) } def location; end # String representing the object's type. Objects of the same type share the same value. @@ -40798,7 +41168,7 @@ module Stripe # Whether the capability has been requested. sig { returns(T::Boolean) } def requested; end - # Time at which the capability was requested. Measured in seconds since the Unix epoch. + # Time when the capability was requested. Measured in seconds since the Unix epoch. sig { returns(T.nilable(Integer)) } def requested_at; end # Attribute for field requirements @@ -40807,13 +41177,13 @@ module Stripe # The status of the capability. sig { returns(String) } def status; end - # Returns a list of PaymentLocationCapability objects associated with the location. + # List all payment location capabilities associated with the payment location. sig { params(params: T.any(::Stripe::PaymentLocationCapabilityListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) } def self.list(params = {}, opts = {}); end - # Updates a specified Payment Location Capability. Request or remove a payment location capability by updating its requested parameter. + # Updates a payment_location capability. Request or remove a payment_location capability by updating its requested parameter. sig { params(capability: String, params: T.any(::Stripe::PaymentLocationCapabilityUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::PaymentLocationCapability) } @@ -40903,7 +41273,7 @@ module Stripe # Identification numbers associated with the location. sig { returns(T.nilable(BusinessRegistration)) } def business_registration; end - # The capability settings for the location. Only applicable for locations with requested Payment Location Capabilities. + # The capability settings for the location. Only applicable for locations with requested payment location capabilities. sig { returns(T.nilable(CapabilitySettings)) } def capability_settings; end # Always true for a deleted object @@ -72199,6 +72569,931 @@ module Stripe end end # typed: true +module Stripe + module V2 + module Billing + # Main Contract resource representing a comprehensive billing agreement + class Contract < APIResource + class BillingSettings < ::Stripe::StripeObject + class ContractBillingDetails < ::Stripe::StripeObject + class BillSettingsDetails < ::Stripe::StripeObject + class Calculation < ::Stripe::StripeObject + class Tax < ::Stripe::StripeObject + # The type of tax calculation. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Tax calculation settings. + sig { returns(T.nilable(Tax)) } + def tax; end + def self.inner_class_types + @inner_class_types = {tax: Tax} + end + def self.field_remappings + @field_remappings = {} + end + end + class Invoice < ::Stripe::StripeObject + class TimeUntilDue < ::Stripe::StripeObject + # The interval unit. + sig { returns(String) } + def interval; end + # The number of intervals. + sig { returns(Integer) } + def interval_count; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The number of time units before the invoice is past due. + sig { returns(T.nilable(TimeUntilDue)) } + def time_until_due; end + def self.inner_class_types + @inner_class_types = {time_until_due: TimeUntilDue} + end + def self.field_remappings + @field_remappings = {} + end + end + # Calculation settings. + sig { returns(T.nilable(Calculation)) } + def calculation; end + # Invoice settings. + sig { returns(T.nilable(Invoice)) } + def invoice; end + def self.inner_class_types + @inner_class_types = {calculation: Calculation, invoice: Invoice} + end + def self.field_remappings + @field_remappings = {} + end + end + class BillingProfileDetails < ::Stripe::StripeObject + # The customer who pays for the contract invoice. + sig { returns(String) } + def customer; end + # The default payment method for the contract. + sig { returns(T.nilable(String)) } + def default_payment_method; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class CollectionSettingsDetails < ::Stripe::StripeObject + # The collection method. + sig { returns(String) } + def collection_method; end + # The payment method configuration. + sig { returns(T.nilable(String)) } + def payment_method_configuration; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The bill settings details. + sig { returns(T.nilable(BillSettingsDetails)) } + def bill_settings_details; end + # The billing profile details. + sig { returns(BillingProfileDetails) } + def billing_profile_details; end + # The collection settings details. + sig { returns(CollectionSettingsDetails) } + def collection_settings_details; end + def self.inner_class_types + @inner_class_types = { + bill_settings_details: BillSettingsDetails, + billing_profile_details: BillingProfileDetails, + collection_settings_details: CollectionSettingsDetails, + } + end + def self.field_remappings + @field_remappings = {} + end + end + # Billing settings details for the contract. + sig { returns(T.nilable(ContractBillingDetails)) } + def contract_billing_details; end + def self.inner_class_types + @inner_class_types = {contract_billing_details: ContractBillingDetails} + end + def self.field_remappings + @field_remappings = {} + end + end + class ContractLineDetail < ::Stripe::StripeObject + class ContractLineValueDetails < ::Stripe::StripeObject + # Computed sum of all licensed fees. Represented as a decimal string in minor currency units. + sig { returns(String) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Override < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class ServiceAction < ::Stripe::StripeObject + class Add < ::Stripe::StripeObject + class CreditGrant < ::Stripe::StripeObject + class Amount < ::Stripe::StripeObject + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class ApplicabilityConfig < ::Stripe::StripeObject + class Scope < ::Stripe::StripeObject + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The applicability scope of the credit grant. + sig { returns(Scope) } + def scope; end + def self.inner_class_types + @inner_class_types = {scope: Scope} + end + def self.field_remappings + @field_remappings = {} + end + end + class ExpiryConfig < ::Stripe::StripeObject + # The type of the expiry configuration. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The amount of the credit grant. + sig { returns(Amount) } + def amount; end + # Defines the scope where the credit grant is applicable. + sig { returns(ApplicabilityConfig) } + def applicability_config; end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + # The expiry configuration for the credit grant. + sig { returns(ExpiryConfig) } + def expiry_config; end + # A descriptive name. + sig { returns(String) } + def name; end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + def self.inner_class_types + @inner_class_types = { + amount: Amount, + applicability_config: ApplicabilityConfig, + expiry_config: ExpiryConfig, + } + end + def self.field_remappings + @field_remappings = {} + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { returns(T.nilable(CreditGrant)) } + def credit_grant; end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + # The type of the service action. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {credit_grant: CreditGrant} + end + def self.field_remappings + @field_remappings = {} + end + end + class Replace < ::Stripe::StripeObject + class CreditGrant < ::Stripe::StripeObject + class Amount < ::Stripe::StripeObject + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class ApplicabilityConfig < ::Stripe::StripeObject + class Scope < ::Stripe::StripeObject + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The applicability scope of the credit grant. + sig { returns(Scope) } + def scope; end + def self.inner_class_types + @inner_class_types = {scope: Scope} + end + def self.field_remappings + @field_remappings = {} + end + end + class ExpiryConfig < ::Stripe::StripeObject + # The type of the expiry configuration. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The amount of the credit grant. + sig { returns(Amount) } + def amount; end + # Defines the scope where the credit grant is applicable. + sig { returns(ApplicabilityConfig) } + def applicability_config; end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + # The expiry configuration for the credit grant. + sig { returns(ExpiryConfig) } + def expiry_config; end + # A descriptive name. + sig { returns(String) } + def name; end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + def self.inner_class_types + @inner_class_types = { + amount: Amount, + applicability_config: ApplicabilityConfig, + expiry_config: ExpiryConfig, + } + end + def self.field_remappings + @field_remappings = {} + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { returns(T.nilable(CreditGrant)) } + def credit_grant; end + # The ID of the service action to replace. + sig { returns(T.nilable(String)) } + def id; end + # The lookup key for the service action to replace. + sig { returns(T.nilable(String)) } + def lookup_key; end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + # The type of the service action. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {credit_grant: CreditGrant} + end + def self.field_remappings + @field_remappings = {} + end + end + # Parameters for adding a new service action. + sig { returns(T.nilable(Add)) } + def add; end + # Parameters for replacing an existing service action. + sig { returns(T.nilable(Replace)) } + def replace; end + # The type of service action override. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {add: Add, replace: Replace} + end + def self.field_remappings + @field_remappings = {} + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Timestamp to indicate when the override ends. + sig { returns(EndsAt) } + def ends_at; end + # Service action override details. + sig { returns(T.nilable(ServiceAction)) } + def service_action; end + # Timestamp to indicate when the override starts. + sig { returns(StartsAt) } + def starts_at; end + # The type of the override. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = { + ends_at: EndsAt, + service_action: ServiceAction, + starts_at: StartsAt, + } + end + def self.field_remappings + @field_remappings = {} + end + end + class Pricing < ::Stripe::StripeObject + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The ID of the contract line. + sig { returns(String) } + def contract_line; end + # The computed value details for the contract line. + sig { returns(ContractLineValueDetails) } + def contract_line_value_details; end + # Timestamp of when the object was created. + sig { returns(String) } + def created; end + # Timestamp to indicate when the contract line ends. + sig { returns(EndsAt) } + def ends_at; end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + # List of overrides applied to the contract line. + sig { returns(T::Array[Override]) } + def overrides; end + # The pricing configuration for the contract line. + sig { returns(Pricing) } + def pricing; end + # Timestamp to indicate when the contract line starts. + sig { returns(StartsAt) } + def starts_at; end + def self.inner_class_types + @inner_class_types = { + contract_line_value_details: ContractLineValueDetails, + ends_at: EndsAt, + overrides: Override, + pricing: Pricing, + starts_at: StartsAt, + } + end + def self.field_remappings + @field_remappings = {} + end + end + class ContractValueDetails < ::Stripe::StripeObject + # The total value represented as a decimal string in minor currency units. + sig { returns(String) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class LicenseQuantity < ::Stripe::StripeObject + # The ID of the license pricing. + sig { returns(String) } + def license_pricing_id; end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + # The ID of the pricing line associated with this license quantity. + sig { returns(String) } + def pricing_line; end + # The current quantity of the license. + sig { returns(Integer) } + def quantity; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class OneTimeFee < ::Stripe::StripeObject + class BillSchedule < ::Stripe::StripeObject + class BillAt < ::Stripe::StripeObject + # The datetime at which the entry will be billed. Set when `type` is `datetime`. + sig { returns(T.nilable(String)) } + def timestamp; end + # The type of the bill_at. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # When this entry will be billed. + sig { returns(BillAt) } + def bill_at; end + # The amount to bill for this entry, in the smallest currency unit. + sig { returns(Integer) } + def value; end + def self.inner_class_types + @inner_class_types = {bill_at: BillAt} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {value: :int64_string} + end + end + class ProductDetails < ::Stripe::StripeObject + # The ID of the v1 Product. + sig { returns(String) } + def product; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The resolved bill schedule for the fee. + sig { returns(T::Array[BillSchedule]) } + def bill_schedule; end + # The type of billable item that this fee references. + sig { returns(String) } + def billable_item_type; end + # Details for a product billable target. Set when `billable_item_type` is `product`. + sig { returns(T.nilable(ProductDetails)) } + def product_details; end + def self.inner_class_types + @inner_class_types = {bill_schedule: BillSchedule, product_details: ProductDetails} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = { + bill_schedule: { + kind: :array, + element: {kind: :object, fields: {value: :int64_string}}, + }, + } + end + end + class PricingLine < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Pricing < ::Stripe::StripeObject + class PriceDetails < ::Stripe::StripeObject + # The ID of the V1 price. + sig { returns(String) } + def price; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # V1 price details. Present when `type` is `price`. + sig { returns(T.nilable(PriceDetails)) } + def price_details; end + # The type of pricing. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {price_details: PriceDetails} + end + def self.field_remappings + @field_remappings = {} + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Resolved timestamp when the pricing line ends. + sig { returns(EndsAt) } + def ends_at; end + # The user-provided lookup key for the pricing line. + sig { returns(T.nilable(String)) } + def lookup_key; end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + # The pricing configuration for the pricing line. + sig { returns(Pricing) } + def pricing; end + # The ID of the pricing line. + sig { returns(String) } + def pricing_line; end + # Resolved timestamp when the pricing line starts. + sig { returns(StartsAt) } + def starts_at; end + def self.inner_class_types + @inner_class_types = {ends_at: EndsAt, pricing: Pricing, starts_at: StartsAt} + end + def self.field_remappings + @field_remappings = {} + end + end + class PricingOverride < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Multiplier < ::Stripe::StripeObject + class Criterion < ::Stripe::StripeObject + class MetadataCondition < ::Stripe::StripeObject + class AllOf < ::Stripe::StripeObject + # The metadata key. + sig { returns(String) } + def key; end + # The metadata value. + sig { returns(String) } + def value; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # All of these key-value conditions must match. + sig { returns(T::Array[AllOf]) } + def all_of; end + def self.inner_class_types + @inner_class_types = {all_of: AllOf} + end + def self.field_remappings + @field_remappings = {} + end + end + # Filter by billable item IDs. + sig { returns(T::Array[String]) } + def billable_item_ids; end + # Filter by billable item lookup keys. + sig { returns(T::Array[String]) } + def billable_item_lookup_keys; end + # Filter by billable item type. + sig { returns(T::Array[String]) } + def billable_item_types; end + # Filter by metadata conditions. + sig { returns(T::Array[MetadataCondition]) } + def metadata_conditions; end + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + sig { returns(T::Array[String]) } + def rate_card_ids; end + # Whether to include or exclude items matching these criteria. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {metadata_conditions: MetadataCondition} + end + def self.field_remappings + @field_remappings = {} + end + end + # Criteria determining which rates the multiplier applies to. + sig { returns(T::Array[Criterion]) } + def criteria; end + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + sig { returns(String) } + def factor; end + def self.inner_class_types + @inner_class_types = {criteria: Criterion} + end + def self.field_remappings + @field_remappings = {} + end + end + class OverwritePrice < ::Stripe::StripeObject + class Tier < ::Stripe::StripeObject + # Price for the entire tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def flat_amount; end + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + # Up to and including this quantity will be contained in the tier. + sig { returns(T.nilable(BigDecimal)) } + def up_to_decimal; end + # No upper bound to this tier. + sig { returns(T.nilable(String)) } + def up_to_inf; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {up_to_decimal: :decimal_string} + end + end + # The ID of the V1 price to overwrite. + sig { returns(String) } + def price; end + # Defines whether the tiered price should be graduated or volume-based. + sig { returns(T.nilable(String)) } + def tiering_mode; end + # Each element represents a pricing tier. + sig { returns(T::Array[Tier]) } + def tiers; end + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + def self.inner_class_types + @inner_class_types = {tiers: Tier} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + } + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Resolved timestamp when the pricing override ends. + sig { returns(EndsAt) } + def ends_at; end + # The user-provided lookup key for the pricing override. + sig { returns(T.nilable(String)) } + def lookup_key; end + # Details for a multiplier override. + sig { returns(T.nilable(Multiplier)) } + def multiplier; end + # Details for an overwrite_price override. + sig { returns(T.nilable(OverwritePrice)) } + def overwrite_price; end + # The ID of the pricing override. + sig { returns(String) } + def pricing_override; end + # The priority of this override relative to others. Lower number = higher priority. + sig { returns(Integer) } + def priority; end + # Resolved timestamp when the pricing override starts. + sig { returns(StartsAt) } + def starts_at; end + # The type of pricing override. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = { + ends_at: EndsAt, + multiplier: Multiplier, + overwrite_price: OverwritePrice, + starts_at: StartsAt, + } + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + } + end + end + class StatusDetails < ::Stripe::StripeObject + class Active < ::Stripe::StripeObject + # The timestamp when the contract was activated. + sig { returns(String) } + def activated_at; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Canceled < ::Stripe::StripeObject + # The timestamp when the contract was canceled. + sig { returns(String) } + def canceled_at; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Details of the active contract status. + sig { returns(T.nilable(Active)) } + def active; end + # Details of the canceled contract status. + sig { returns(T.nilable(Canceled)) } + def canceled; end + def self.inner_class_types + @inner_class_types = {active: Active, canceled: Canceled} + end + def self.field_remappings + @field_remappings = {} + end + end + # The billing settings for the contract. + sig { returns(T.nilable(BillingSettings)) } + def billing_settings; end + # The contract line details of the contract. Only populated when `contract_line_details` is passed in the `include` parameter. + sig { returns(T::Array[ContractLineDetail]) } + def contract_line_details; end + # A unique user-provided contract number e.g. C-2026-0001. + sig { returns(String) } + def contract_number; end + # The computed total value of all contract lines. + sig { returns(ContractValueDetails) } + def contract_value_details; end + # Timestamp of when the object was created. + sig { returns(String) } + def created; end + # The currency of the contract. + sig { returns(String) } + def currency; end + # The ID of the customer associated with the contract. + sig { returns(String) } + def customer; end + # The ID of the contract object. + sig { returns(String) } + def id; end + # The license quantities of the contract. Only populated when `license_quantities` is passed in the `include` parameter. + sig { returns(T::Array[LicenseQuantity]) } + def license_quantities; end + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + sig { returns(T::Boolean) } + def livemode; end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + # String representing the object's type. Objects of the same type share the same value of the object field. + sig { returns(String) } + def object; end + # The one-time fees of the contract. Only populated when `one_time_fees` is passed in the `include` parameter. + sig { returns(T.nilable(T::Array[OneTimeFee])) } + def one_time_fees; end + # The pricing lines of the contract. Only populated when `pricing_lines` is passed in the `include` parameter. + sig { returns(T::Array[PricingLine]) } + def pricing_lines; end + # The pricing overrides of the contract. Only populated when `pricing_overrides` is passed in the `include` parameter. + sig { returns(T::Array[PricingOverride]) } + def pricing_overrides; end + # The current status of the contract. + sig { returns(String) } + def status; end + # Information about the contract status transitions. + sig { returns(StatusDetails) } + def status_details; end + end + end + end +end +# typed: true module Stripe module V2 module Billing @@ -84504,17 +85799,34 @@ module Stripe @field_remappings = {} end end + class Schema < ::Stripe::StripeObject + # The name of the column. + sig { returns(String) } + def name; end + # The type of the column. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end # The content type of the file. sig { returns(String) } def content_type; end # A pre-signed URL that allows secure, time-limited access to download the file. sig { returns(DownloadUrl) } def download_url; end + # The columns of the schema. + sig { returns(T::Array[Schema]) } + def schema; end # The total size of the file in bytes. sig { returns(Integer) } def size; end def self.inner_class_types - @inner_class_types = {download_url: DownloadUrl} + @inner_class_types = {download_url: DownloadUrl, schema: Schema} end def self.field_remappings @field_remappings = {} @@ -88757,17 +90069,34 @@ module Stripe @field_remappings = {} end end + class Schema < ::Stripe::StripeObject + # The name of the column. + sig { returns(String) } + def name; end + # The type of the column. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end # The content type of the file. sig { returns(String) } def content_type; end # A pre-signed URL that allows secure, time-limited access to download the file. sig { returns(DownloadUrl) } def download_url; end + # The columns of the schema. + sig { returns(T::Array[Schema]) } + def schema; end # The total size of the file in bytes. sig { returns(Integer) } def size; end def self.inner_class_types - @inner_class_types = {download_url: DownloadUrl} + @inner_class_types = {download_url: DownloadUrl, schema: Schema} end def self.field_remappings @field_remappings = {} @@ -88964,6 +90293,132 @@ module Stripe end end # typed: true +module Stripe + module V2 + module Signals + # An automatically evaluated signal on a v2 account. + class AccountSignal < APIResource + class AccountDetails < ::Stripe::StripeObject + # The v2 account ID of the account. + sig { returns(T.nilable(String)) } + def account; end + # The v1 customer ID of the account, for users not yet migrated to v2/accounts. + sig { returns(T.nilable(String)) } + def customer; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class FraudulentMerchant < ::Stripe::StripeObject + class Indicator < ::Stripe::StripeObject + # A brief explanation of how this indicator contributed to the fraudulent merchant probability. + sig { returns(String) } + def explanation; end + # The effect this indicator had on the overall risk level. + sig { returns(String) } + def impact; end + # The name of the specific indicator used in the risk assessment. + sig { returns(String) } + def indicator; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Array of objects representing individual factors that contributed to the calculated probability. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes indicators. + sig { returns(T::Array[Indicator]) } + def indicators; end + # The probability of the merchant being fraudulent. Can be between 0.00 and 100.00. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes numeric scores. + sig { returns(T.nilable(BigDecimal)) } + def probability; end + # Categorical assessment of the fraudulent merchant risk based on probability. + sig { returns(String) } + def risk_level; end + def self.inner_class_types + @inner_class_types = {indicators: Indicator} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {probability: :decimal_string} + end + end + class MerchantDelinquency < ::Stripe::StripeObject + class Indicator < ::Stripe::StripeObject + # A brief explanation of how this indicator contributed to the delinquency probability. + sig { returns(String) } + def explanation; end + # The effect this indicator had on the overall risk level. + sig { returns(String) } + def impact; end + # The name of the specific indicator used in the risk assessment. + sig { returns(String) } + def indicator; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Array of objects representing individual factors that contributed to the calculated probability of delinquency. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes indicators. + sig { returns(T::Array[Indicator]) } + def indicators; end + # The probability of delinquency. Can be between 0.00 and 100.00. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes numeric scores. + sig { returns(T.nilable(BigDecimal)) } + def probability; end + # Categorical assessment of the delinquency risk based on probability. + sig { returns(String) } + def risk_level; end + def self.inner_class_types + @inner_class_types = {indicators: Indicator} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {probability: :decimal_string} + end + end + # The account or customer this signal is associated with. + sig { returns(T.nilable(AccountDetails)) } + def account_details; end + # Timestamp at which the signal was created. + sig { returns(String) } + def created; end + # Data for the fraudulent merchant signal. Present only when type is fraudulent_merchant. + sig { returns(T.nilable(FraudulentMerchant)) } + def fraudulent_merchant; end + # Unique identifier for the account signal. + sig { returns(String) } + def id; end + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + sig { returns(T::Boolean) } + def livemode; end + # Data for the merchant delinquency signal. Present only when type is merchant_delinquency. + sig { returns(T.nilable(MerchantDelinquency)) } + def merchant_delinquency; end + # String representing the object's type. Objects of the same type share the same value of the object field. + sig { returns(String) } + def object; end + # The type of signal. + sig { returns(String) } + def type; end + end + end + end +end +# typed: true module Stripe module V2 module Tax @@ -90619,13 +92074,27 @@ end # typed: true module Stripe class DelegatedCheckoutService < StripeService + attr_reader :orders attr_reader :requested_sessions end end # typed: true +module Stripe + module DelegatedCheckout + class OrderService < StripeService + # Retrieves a delegated checkout order. + sig { + params(order_id: String, params: T.any(::Stripe::DelegatedCheckout::OrderRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::DelegatedCheckout::Order) + } + def retrieve(order_id, params = {}, opts = {}); end + end + end +end +# typed: true module Stripe module DelegatedCheckout class RequestedSessionService < StripeService + attr_reader :orders # Confirms a requested session sig { params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::DelegatedCheckout::RequestedSession) @@ -90659,6 +92128,18 @@ module Stripe end end # typed: true +module Stripe + module DelegatedCheckout + class RequestedSessionOrderService < StripeService + # Lists orders for a delegated checkout requested session. + sig { + params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionOrderListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) + } + def list(requested_session, params = {}, opts = {}); end + end + end +end +# typed: true module Stripe class DisputeService < StripeService # Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost. @@ -92401,19 +93882,19 @@ end # typed: true module Stripe class PaymentLocationCapabilityService < StripeService - # Returns a list of PaymentLocationCapability objects associated with the location. + # List all payment location capabilities associated with the payment location. sig { params(params: T.any(::Stripe::PaymentLocationCapabilityListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) } def list(params = {}, opts = {}); end - # Retrieves information about the specified Payment Location Capability. + # Retrieves a payment_location capability sig { params(capability: String, params: T.any(::Stripe::PaymentLocationCapabilityRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::PaymentLocationCapability) } def retrieve(capability, params = {}, opts = {}); end - # Updates a specified Payment Location Capability. Request or remove a payment location capability by updating its requested parameter. + # Updates a payment_location capability. Request or remove a payment_location capability by updating its requested parameter. sig { params(capability: String, params: T.any(::Stripe::PaymentLocationCapabilityUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::PaymentLocationCapability) } @@ -95398,6 +96879,7 @@ module Stripe attr_reader :orchestrated_commerce attr_reader :payments attr_reader :reporting + attr_reader :signals attr_reader :tax attr_reader :test_helpers end @@ -95409,6 +96891,7 @@ module Stripe attr_reader :bill_settings attr_reader :cadences attr_reader :collection_settings + attr_reader :contracts attr_reader :custom_pricing_units attr_reader :intents attr_reader :license_fees @@ -95600,6 +97083,81 @@ module Stripe end end # typed: true +module Stripe + module V2 + module Billing + class ContractService < StripeService + attr_reader :license_pricing + # Activate a Draft Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractActivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def activate(id, params = {}, opts = {}); end + + # Cancel a Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractCancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def cancel(id, params = {}, opts = {}); end + + # Create a Contract object. + sig { + params(params: T.any(::Stripe::V2::Billing::ContractCreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def create(params = {}, opts = {}); end + + # List Contract objects with pagination. + sig { + params(params: T.any(::Stripe::V2::Billing::ContractListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::ListObject) + } + def list(params = {}, opts = {}); end + + # Retrieve a Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def retrieve(id, params = {}, opts = {}); end + + # Update a Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def update(id, params = {}, opts = {}); end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + module Contracts + class LicensePricingService < StripeService + attr_reader :quantity_changes + end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + module Contracts + module LicensePricing + class QuantityChangeService < StripeService + # List license quantity changes for a contract given a license pricing ID. + sig { + params(contract_id: String, license_pricing_id: String, params: T.any(::Stripe::V2::Billing::Contracts::LicensePricing::QuantityChangeListQuantityChangesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::ListObject) + } + def list_quantity_changes(contract_id, license_pricing_id, params = {}, opts = {}); end + end + end + end + end + end +end +# typed: true module Stripe module V2 module Billing @@ -97695,7 +99253,7 @@ end # typed: true module Stripe module V2 - class PaymentService < StripeService + class PaymentsService < StripeService attr_reader :off_session_payments attr_reader :settlement_allocation_intents end @@ -97882,6 +99440,34 @@ module Stripe end end # typed: true +module Stripe + module V2 + class SignalsService < StripeService + attr_reader :account_signals + end + end +end +# typed: true +module Stripe + module V2 + module Signals + class AccountSignalService < StripeService + # Lists AccountSignals for a given account or customer, filtered by signal type. + sig { + params(params: T.any(::Stripe::V2::Signals::AccountSignalListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::ListObject) + } + def list(params = {}, opts = {}); end + + # Retrieves an AccountSignal by its ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Signals::AccountSignalRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Signals::AccountSignal) + } + def retrieve(id, params = {}, opts = {}); end + end + end + end +end +# typed: true module Stripe module V2 class TaxService < StripeService @@ -102300,6 +103886,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -102502,6 +104131,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji)).returns(T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji)) } def address_kanji=(_address_kanji); end + # Attribute for param field birth_address + sig { returns(T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress)).returns(T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress)) + } + def birth_address=(_birth_address); end # The individual's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountUpdateParams::Individual::Dob))) } def dob; end @@ -102631,12 +104267,13 @@ module Stripe } def verification=(_verification); end sig { - params(address: T.nilable(::Stripe::AccountUpdateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountUpdateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountUpdateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountUpdateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountUpdateParams::Individual::Verification)).void + params(address: T.nilable(::Stripe::AccountUpdateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji), birth_address: T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountUpdateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountUpdateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountUpdateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountUpdateParams::Individual::Verification)).void } def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, @@ -106123,6 +107760,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -106325,6 +108005,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji)).returns(T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji)) } def address_kanji=(_address_kanji); end + # Attribute for param field birth_address + sig { returns(T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress)).returns(T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress)) + } + def birth_address=(_birth_address); end # The individual's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountCreateParams::Individual::Dob))) } def dob; end @@ -106454,12 +108141,13 @@ module Stripe } def verification=(_verification); end sig { - params(address: T.nilable(::Stripe::AccountCreateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountCreateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountCreateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountCreateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountCreateParams::Individual::Verification)).void + params(address: T.nilable(::Stripe::AccountCreateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji), birth_address: T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountCreateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountCreateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountCreateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountCreateParams::Individual::Verification)).void } def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, @@ -113836,12 +115524,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -116983,12 +118673,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -127193,6 +128885,37 @@ module Stripe end end # typed: true +module Stripe + module DelegatedCheckout + class RequestedSessionListOrdersParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + sig { returns(T.nilable(String)) } + def ending_before; end + sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } + def ending_before=(_ending_before); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + sig { returns(T.nilable(String)) } + def starting_after; end + sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } + def starting_after=(_starting_after); end + sig { + params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void + } + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end + end + end +end +# typed: true module Stripe module DelegatedCheckout class RequestedSessionCreateParams < ::Stripe::RequestParams @@ -157408,12 +159131,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -159234,6 +160959,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -159253,9 +160983,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -159734,6 +161464,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -159753,9 +161488,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -159891,8 +161626,13 @@ module Stripe def networks; end sig { params(_networks: T::Array[String]).returns(T::Array[String]) } def networks=(_networks); end - sig { params(networks: T::Array[String]).void } - def initialize(networks: nil); end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end + sig { params(_static_address: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def static_address=(_static_address); end + sig { params(networks: T::Array[String], static_address: T.nilable(T::Boolean)).void } + def initialize(networks: nil, static_address: nil); end end # Specific configuration for this PaymentIntent when the mode is `deposit`. sig { @@ -163597,33 +165337,18 @@ module Stripe ); end end class PaymentsOrchestration < ::Stripe::RequestParams - class PaymentDetails < ::Stripe::RequestParams - # Merchant-provided reference for this payment, used for reconciliation. - sig { returns(T.nilable(String)) } - def reference; end - sig { params(_reference: T.nilable(String)).returns(T.nilable(String)) } - def reference=(_reference); end - sig { params(reference: T.nilable(String)).void } - def initialize(reference: nil); end - end # Whether this feature is enabled. sig { returns(T::Boolean) } def enabled; end sig { params(_enabled: T::Boolean).returns(T::Boolean) } def enabled=(_enabled); end - # Payment-level details for the orchestrated payment. - sig { - returns(T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)) - } - def payment_details; end - sig { - params(_payment_details: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)).returns(T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)) - } - def payment_details=(_payment_details); end - sig { - params(enabled: T::Boolean, payment_details: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)).void - } - def initialize(enabled: nil, payment_details: nil); end + # Merchant-provided reference for this payment, used for reconciliation. + sig { returns(T.nilable(String)) } + def payment_reference; end + sig { params(_payment_reference: T.nilable(String)).returns(T.nilable(String)) } + def payment_reference=(_payment_reference); end + sig { params(enabled: T::Boolean, payment_reference: T.nilable(String)).void } + def initialize(enabled: nil, payment_reference: nil); end end class RadarOptions < ::Stripe::RequestParams # A [Radar Session](https://docs.stripe.com/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments. @@ -167348,12 +169073,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -169174,6 +170901,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -169193,9 +170925,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -169674,6 +171406,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -169693,9 +171430,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -169831,8 +171568,13 @@ module Stripe def networks; end sig { params(_networks: T::Array[String]).returns(T::Array[String]) } def networks=(_networks); end - sig { params(networks: T::Array[String]).void } - def initialize(networks: nil); end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end + sig { params(_static_address: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def static_address=(_static_address); end + sig { params(networks: T::Array[String], static_address: T.nilable(T::Boolean)).void } + def initialize(networks: nil, static_address: nil); end end # Specific configuration for this PaymentIntent when the mode is `deposit`. sig { @@ -177136,12 +178878,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -180699,12 +182443,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -182533,6 +184279,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -182552,9 +184303,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -183033,6 +184784,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -183052,9 +184808,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -183190,8 +184946,13 @@ module Stripe def networks; end sig { params(_networks: T::Array[String]).returns(T::Array[String]) } def networks=(_networks); end - sig { params(networks: T::Array[String]).void } - def initialize(networks: nil); end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end + sig { params(_static_address: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def static_address=(_static_address); end + sig { params(networks: T::Array[String], static_address: T.nilable(T::Boolean)).void } + def initialize(networks: nil, static_address: nil); end end # Specific configuration for this PaymentIntent when the mode is `deposit`. sig { @@ -190768,7 +192529,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # The location for which the capabilities enable functionality. + # The payment location that the capabilities enable functionality for. sig { returns(String) } def location; end sig { params(_location: String).returns(String) } @@ -190785,7 +192546,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # The location for which the capability enables functionality. + # The location that the capability enables functionality for. sig { returns(String) } def location; end sig { params(_location: String).returns(String) } @@ -190884,7 +192645,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # Pass true when updating location fields that will trigger onboarding review for any of the location's active location capabilities. If this parameter is not set to true, updates that would trigger onboarding review will fail. Only applicable for locations with active location capabilities. + # Pass true when updating location fields that trigger onboarding review for any of the location's active location capabilities. If this parameter isn't set to true, updates that would trigger onboarding review fail. Only applicable for locations with active location capabilities. sig { returns(T.nilable(T::Boolean)) } def onboarding_data_update_acknowledged; end sig { @@ -190906,13 +192667,30 @@ end # typed: true module Stripe class PaymentLocationListParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + sig { returns(T.nilable(String)) } + def ending_before; end + sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } + def ending_before=(_ending_before); end # Specifies which fields in the response should be expanded. sig { returns(T.nilable(T::Array[String])) } def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + sig { returns(T.nilable(String)) } + def starting_after; end + sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } + def starting_after=(_starting_after); end + sig { + params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void + } + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end end end # typed: true @@ -206681,9 +208459,9 @@ module Stripe sig { params(_created_at: Integer).returns(Integer) } def created_at=(_created_at); end # The last 4 digits of the card number. - sig { returns(T.nilable(String)) } + sig { returns(String) } def last4; end - sig { params(_last4: T.nilable(String)).returns(T.nilable(String)) } + sig { params(_last4: String).returns(String) } def last4=(_last4); end # User's specified unique ID of the card for this authorization attempt (e.g., RRN or internal reference). sig { returns(String) } @@ -206691,7 +208469,7 @@ module Stripe sig { params(_reference: String).returns(String) } def reference=(_reference); end sig { - params(bin: String, bin_country: String, card_type: String, created_at: Integer, last4: T.nilable(String), reference: String).void + params(bin: String, bin_country: String, card_type: String, created_at: Integer, last4: String, reference: String).void } def initialize( bin: nil, @@ -235002,6 +236780,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -235204,6 +237025,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji)).returns(T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji)) } def address_kanji=(_address_kanji); end + # Attribute for param field birth_address + sig { returns(T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress)).returns(T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress)) + } + def birth_address=(_birth_address); end # The individual's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::TokenCreateParams::Account::Individual::Dob))) @@ -235339,12 +237167,13 @@ module Stripe } def verification=(_verification); end sig { - params(address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Account::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Verification)).void + params(address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji), birth_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Account::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Verification)).void } def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, @@ -235741,6 +237570,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -236081,6 +237953,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji)).returns(T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji)) } def address_kanji=(_address_kanji); end + # The person's place of birth. + sig { returns(T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress)).returns(T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress)) + } + def birth_address=(_birth_address); end # The person's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::TokenCreateParams::Person::Dob))) } def dob; end @@ -236229,13 +238108,14 @@ module Stripe } def verification=(_verification); end sig { - params(additional_tos_acceptances: T.nilable(::Stripe::TokenCreateParams::Person::AdditionalTosAcceptances), address: T.nilable(::Stripe::TokenCreateParams::Person::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Person::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Person::Dob)), documents: T.nilable(::Stripe::TokenCreateParams::Person::Documents), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Person::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Person::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::TokenCreateParams::Person::UsCfpbData), verification: T.nilable(::Stripe::TokenCreateParams::Person::Verification)).void + params(additional_tos_acceptances: T.nilable(::Stripe::TokenCreateParams::Person::AdditionalTosAcceptances), address: T.nilable(::Stripe::TokenCreateParams::Person::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Person::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji), birth_address: T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Person::Dob)), documents: T.nilable(::Stripe::TokenCreateParams::Person::Documents), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Person::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Person::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::TokenCreateParams::Person::UsCfpbData), verification: T.nilable(::Stripe::TokenCreateParams::Person::Verification)).void } def initialize( additional_tos_acceptances: nil, address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, @@ -240483,82 +242363,125 @@ module Stripe town: nil ); end end - class Dob < ::Stripe::RequestParams - # The day of birth, between 1 and 31. - sig { returns(Integer) } - def day; end - sig { params(_day: Integer).returns(Integer) } - def day=(_day); end - # The month of birth, between 1 and 12. - sig { returns(Integer) } - def month; end - sig { params(_month: Integer).returns(Integer) } - def month=(_month); end - # The four-digit year of birth. - sig { returns(Integer) } - def year; end - sig { params(_year: Integer).returns(Integer) } - def year=(_year); end - sig { params(day: Integer, month: Integer, year: Integer).void } - def initialize(day: nil, month: nil, year: nil); end - end - class Documents < ::Stripe::RequestParams - class CompanyAuthorization < ::Stripe::RequestParams - # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. - sig { returns(T.nilable(T::Array[String])) } - def files; end - sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def files=(_files); end - sig { params(files: T.nilable(T::Array[String])).void } - def initialize(files: nil); end - end - class Passport < ::Stripe::RequestParams - # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. - sig { returns(T.nilable(T::Array[String])) } - def files; end - sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def files=(_files); end - sig { params(files: T.nilable(T::Array[String])).void } - def initialize(files: nil); end - end - class Visa < ::Stripe::RequestParams - # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. - sig { returns(T.nilable(T::Array[String])) } - def files; end - sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def files=(_files); end - sig { params(files: T.nilable(T::Array[String])).void } - def initialize(files: nil); end - end - # One or more documents that demonstrate proof that this person is authorized to represent the company. - sig { - returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization)) - } - def company_authorization; end - sig { - params(_company_authorization: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization)) - } - def company_authorization=(_company_authorization); end - # One or more documents showing the person's passport page with photo and personal data. - sig { returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport)) } - def passport; end - sig { - params(_passport: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport)) - } - def passport=(_passport); end - # One or more documents showing the person's visa required for living in the country where they are residing. - sig { returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)) } - def visa; end - sig { - params(_visa: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)) - } - def visa=(_visa); end - sig { - params(company_authorization: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport), visa: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)).void - } - def initialize(company_authorization: nil, passport: nil, visa: nil); end - end - class RegisteredAddress < ::Stripe::RequestParams + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end + class Dob < ::Stripe::RequestParams + # The day of birth, between 1 and 31. + sig { returns(Integer) } + def day; end + sig { params(_day: Integer).returns(Integer) } + def day=(_day); end + # The month of birth, between 1 and 12. + sig { returns(Integer) } + def month; end + sig { params(_month: Integer).returns(Integer) } + def month=(_month); end + # The four-digit year of birth. + sig { returns(Integer) } + def year; end + sig { params(_year: Integer).returns(Integer) } + def year=(_year); end + sig { params(day: Integer, month: Integer, year: Integer).void } + def initialize(day: nil, month: nil, year: nil); end + end + class Documents < ::Stripe::RequestParams + class CompanyAuthorization < ::Stripe::RequestParams + # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. + sig { returns(T.nilable(T::Array[String])) } + def files; end + sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def files=(_files); end + sig { params(files: T.nilable(T::Array[String])).void } + def initialize(files: nil); end + end + class Passport < ::Stripe::RequestParams + # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. + sig { returns(T.nilable(T::Array[String])) } + def files; end + sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def files=(_files); end + sig { params(files: T.nilable(T::Array[String])).void } + def initialize(files: nil); end + end + class Visa < ::Stripe::RequestParams + # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. + sig { returns(T.nilable(T::Array[String])) } + def files; end + sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def files=(_files); end + sig { params(files: T.nilable(T::Array[String])).void } + def initialize(files: nil); end + end + # One or more documents that demonstrate proof that this person is authorized to represent the company. + sig { + returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization)) + } + def company_authorization; end + sig { + params(_company_authorization: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization)) + } + def company_authorization=(_company_authorization); end + # One or more documents showing the person's passport page with photo and personal data. + sig { returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport)) } + def passport; end + sig { + params(_passport: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport)) + } + def passport=(_passport); end + # One or more documents showing the person's visa required for living in the country where they are residing. + sig { returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)) } + def visa; end + sig { + params(_visa: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)) + } + def visa=(_visa); end + sig { + params(company_authorization: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Passport), visa: T.nilable(::Stripe::AccountPersonUpdateParams::Documents::Visa)).void + } + def initialize(company_authorization: nil, passport: nil, visa: nil); end + end + class RegisteredAddress < ::Stripe::RequestParams # City, district, suburb, town, or village. sig { returns(T.nilable(String)) } def city; end @@ -240819,6 +242742,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji)) } def address_kanji=(_address_kanji); end + # The person's place of birth. + sig { returns(T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress)) + } + def birth_address=(_birth_address); end # The person's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountPersonUpdateParams::Dob))) } def dob; end @@ -240977,13 +242907,14 @@ module Stripe } def verification=(_verification); end sig { - params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonUpdateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonUpdateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountPersonUpdateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonUpdateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonUpdateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonUpdateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonUpdateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonUpdateParams::Verification)).void + params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonUpdateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonUpdateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji), birth_address: T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountPersonUpdateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonUpdateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonUpdateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonUpdateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonUpdateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonUpdateParams::Verification)).void } def initialize( additional_tos_acceptances: nil, address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, @@ -241279,6 +243210,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -241615,6 +243589,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji)).returns(T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji)) } def address_kanji=(_address_kanji); end + # The person's place of birth. + sig { returns(T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress)).returns(T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress)) + } + def birth_address=(_birth_address); end # The person's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountPersonCreateParams::Dob))) } def dob; end @@ -241773,13 +243754,14 @@ module Stripe } def verification=(_verification); end sig { - params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonCreateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonCreateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonCreateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountPersonCreateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonCreateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonCreateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonCreateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonCreateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonCreateParams::Verification)).void + params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonCreateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonCreateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonCreateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji), birth_address: T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountPersonCreateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonCreateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonCreateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonCreateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonCreateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonCreateParams::Verification)).void } def initialize( additional_tos_acceptances: nil, address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, @@ -243565,47 +245547,7 @@ end # typed: true module Stripe module DelegatedCheckout - class RequestedSessionRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end - end -end -# typed: true -module Stripe - class DisputeRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end -end -# typed: true -module Stripe - module Entitlements - class ActiveEntitlementRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end - end -end -# typed: true -module Stripe - module Entitlements - class FeatureRetrieveParams < ::Stripe::RequestParams + class OrderRetrieveParams < ::Stripe::RequestParams # Specifies which fields in the response should be expanded. sig { returns(T.nilable(T::Array[String])) } def expand; end @@ -243618,489 +245560,8 @@ module Stripe end # typed: true module Stripe - class EphemeralKeyCreateParams < ::Stripe::RequestParams - # The ID of the Customer you'd like to modify using the resulting ephemeral key. - sig { returns(T.nilable(String)) } - def customer; end - sig { params(_customer: T.nilable(String)).returns(T.nilable(String)) } - def customer=(_customer); end - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - # The ID of the Issuing Card you'd like to access using the resulting ephemeral key. - sig { returns(T.nilable(String)) } - def issuing_card; end - sig { params(_issuing_card: T.nilable(String)).returns(T.nilable(String)) } - def issuing_card=(_issuing_card); end - # A single-use token, created by Stripe.js, used for creating ephemeral keys for Issuing Cards without exchanging sensitive information. - sig { returns(T.nilable(String)) } - def nonce; end - sig { params(_nonce: T.nilable(String)).returns(T.nilable(String)) } - def nonce=(_nonce); end - # The ID of the Identity VerificationSession you'd like to access using the resulting ephemeral key - sig { returns(T.nilable(String)) } - def verification_session; end - sig { params(_verification_session: T.nilable(String)).returns(T.nilable(String)) } - def verification_session=(_verification_session); end - sig { - params(customer: T.nilable(String), expand: T.nilable(T::Array[String]), issuing_card: T.nilable(String), nonce: T.nilable(String), verification_session: T.nilable(String)).void - } - def initialize( - customer: nil, - expand: nil, - issuing_card: nil, - nonce: nil, - verification_session: nil - ); end - end -end -# typed: true -module Stripe - class EventRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end -end -# typed: true -module Stripe - class ExchangeRateRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end -end -# typed: true -module Stripe - class ExternalAccountDeleteParams < ::Stripe::RequestParams; end -end -# typed: true -module Stripe - class ExternalAccountRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end -end -# typed: true -module Stripe - class ExternalAccountUpdateParams < ::Stripe::RequestParams - class Documents < ::Stripe::RequestParams - class BankAccountOwnershipVerification < ::Stripe::RequestParams - # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. - sig { returns(T.nilable(T::Array[String])) } - def files; end - sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def files=(_files); end - sig { params(files: T.nilable(T::Array[String])).void } - def initialize(files: nil); end - end - # One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check. - sig { - returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)) - } - def bank_account_ownership_verification; end - sig { - params(_bank_account_ownership_verification: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)).returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)) - } - def bank_account_ownership_verification=(_bank_account_ownership_verification); end - sig { - params(bank_account_ownership_verification: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)).void - } - def initialize(bank_account_ownership_verification: nil); end - end - # The name of the person or business that owns the bank account. - sig { returns(T.nilable(String)) } - def account_holder_name; end - sig { params(_account_holder_name: T.nilable(String)).returns(T.nilable(String)) } - def account_holder_name=(_account_holder_name); end - # The type of entity that holds the account. This can be either `individual` or `company`. - sig { returns(T.nilable(T.any(String, String))) } - def account_holder_type; end - sig { - params(_account_holder_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) - } - def account_holder_type=(_account_holder_type); end - # The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`. - sig { returns(T.nilable(String)) } - def account_type; end - sig { params(_account_type: T.nilable(String)).returns(T.nilable(String)) } - def account_type=(_account_type); end - # City/District/Suburb/Town/Village. - sig { returns(T.nilable(String)) } - def address_city; end - sig { params(_address_city: T.nilable(String)).returns(T.nilable(String)) } - def address_city=(_address_city); end - # Billing address country, if provided when creating card. - sig { returns(T.nilable(String)) } - def address_country; end - sig { params(_address_country: T.nilable(String)).returns(T.nilable(String)) } - def address_country=(_address_country); end - # Address line 1 (Street address/PO Box/Company name). - sig { returns(T.nilable(String)) } - def address_line1; end - sig { params(_address_line1: T.nilable(String)).returns(T.nilable(String)) } - def address_line1=(_address_line1); end - # Address line 2 (Apartment/Suite/Unit/Building). - sig { returns(T.nilable(String)) } - def address_line2; end - sig { params(_address_line2: T.nilable(String)).returns(T.nilable(String)) } - def address_line2=(_address_line2); end - # State/County/Province/Region. - sig { returns(T.nilable(String)) } - def address_state; end - sig { params(_address_state: T.nilable(String)).returns(T.nilable(String)) } - def address_state=(_address_state); end - # ZIP or postal code. - sig { returns(T.nilable(String)) } - def address_zip; end - sig { params(_address_zip: T.nilable(String)).returns(T.nilable(String)) } - def address_zip=(_address_zip); end - # When set to true, this becomes the default external account for its currency. - sig { returns(T.nilable(T::Boolean)) } - def default_for_currency; end - sig { params(_default_for_currency: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } - def default_for_currency=(_default_for_currency); end - # Documents that may be submitted to satisfy various informational requests. - sig { returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents)) } - def documents; end - sig { - params(_documents: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents)).returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents)) - } - def documents=(_documents); end - # Two digit number representing the card’s expiration month. - sig { returns(T.nilable(String)) } - def exp_month; end - sig { params(_exp_month: T.nilable(String)).returns(T.nilable(String)) } - def exp_month=(_exp_month); end - # Four digit number representing the card’s expiration year. - sig { returns(T.nilable(String)) } - def exp_year; end - sig { params(_exp_year: T.nilable(String)).returns(T.nilable(String)) } - def exp_year=(_exp_year); end - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - # Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. - sig { returns(T.nilable(T.any(String, T::Hash[String, String]))) } - def metadata; end - sig { - params(_metadata: T.nilable(T.any(String, T::Hash[String, String]))).returns(T.nilable(T.any(String, T::Hash[String, String]))) - } - def metadata=(_metadata); end - # Cardholder name. - sig { returns(T.nilable(String)) } - def name; end - sig { params(_name: T.nilable(String)).returns(T.nilable(String)) } - def name=(_name); end - sig { - params(account_holder_name: T.nilable(String), account_holder_type: T.nilable(T.any(String, String)), account_type: T.nilable(String), address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), default_for_currency: T.nilable(T::Boolean), documents: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents), exp_month: T.nilable(String), exp_year: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.any(String, T::Hash[String, String])), name: T.nilable(String)).void - } - def initialize( - account_holder_name: nil, - account_holder_type: nil, - account_type: nil, - address_city: nil, - address_country: nil, - address_line1: nil, - address_line2: nil, - address_state: nil, - address_zip: nil, - default_for_currency: nil, - documents: nil, - exp_month: nil, - exp_year: nil, - expand: nil, - metadata: nil, - name: nil - ); end - end -end -# typed: true -module Stripe - class ExternalAccountListParams < ::Stripe::RequestParams - # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. - sig { returns(T.nilable(String)) } - def ending_before; end - sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } - def ending_before=(_ending_before); end - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. - sig { returns(T.nilable(Integer)) } - def limit; end - sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } - def limit=(_limit); end - # Filter external accounts according to a particular object type. - sig { returns(T.nilable(String)) } - def object; end - sig { params(_object: T.nilable(String)).returns(T.nilable(String)) } - def object=(_object); end - # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. - sig { returns(T.nilable(String)) } - def starting_after; end - sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } - def starting_after=(_starting_after); end - sig { - params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), object: T.nilable(String), starting_after: T.nilable(String)).void - } - def initialize( - ending_before: nil, - expand: nil, - limit: nil, - object: nil, - starting_after: nil - ); end - end -end -# typed: true -module Stripe - class ExternalAccountCreateParams < ::Stripe::RequestParams - class BankAccount < ::Stripe::RequestParams - # Attribute for param field object - sig { returns(String) } - def object; end - sig { params(_object: String).returns(String) } - def object=(_object); end - # The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object. - sig { returns(T.nilable(String)) } - def account_holder_name; end - sig { params(_account_holder_name: T.nilable(String)).returns(T.nilable(String)) } - def account_holder_name=(_account_holder_name); end - # The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object. - sig { returns(T.nilable(String)) } - def account_holder_type; end - sig { params(_account_holder_type: T.nilable(String)).returns(T.nilable(String)) } - def account_holder_type=(_account_holder_type); end - # The account number for the bank account, in string form. Must be a checking account. - sig { returns(String) } - def account_number; end - sig { params(_account_number: String).returns(String) } - def account_number=(_account_number); end - # The country in which the bank account is located. - sig { returns(String) } - def country; end - sig { params(_country: String).returns(String) } - def country=(_country); end - # The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts) - sig { returns(T.nilable(String)) } - def currency; end - sig { params(_currency: T.nilable(String)).returns(T.nilable(String)) } - def currency=(_currency); end - # The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required. - sig { returns(T.nilable(String)) } - def routing_number; end - sig { params(_routing_number: T.nilable(String)).returns(T.nilable(String)) } - def routing_number=(_routing_number); end - sig { - params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void - } - def initialize( - object: nil, - account_holder_name: nil, - account_holder_type: nil, - account_number: nil, - country: nil, - currency: nil, - routing_number: nil - ); end - end - class Card < ::Stripe::RequestParams - # Attribute for param field object - sig { returns(String) } - def object; end - sig { params(_object: String).returns(String) } - def object=(_object); end - # Attribute for param field address_city - sig { returns(T.nilable(String)) } - def address_city; end - sig { params(_address_city: T.nilable(String)).returns(T.nilable(String)) } - def address_city=(_address_city); end - # Attribute for param field address_country - sig { returns(T.nilable(String)) } - def address_country; end - sig { params(_address_country: T.nilable(String)).returns(T.nilable(String)) } - def address_country=(_address_country); end - # Attribute for param field address_line1 - sig { returns(T.nilable(String)) } - def address_line1; end - sig { params(_address_line1: T.nilable(String)).returns(T.nilable(String)) } - def address_line1=(_address_line1); end - # Attribute for param field address_line2 - sig { returns(T.nilable(String)) } - def address_line2; end - sig { params(_address_line2: T.nilable(String)).returns(T.nilable(String)) } - def address_line2=(_address_line2); end - # Attribute for param field address_state - sig { returns(T.nilable(String)) } - def address_state; end - sig { params(_address_state: T.nilable(String)).returns(T.nilable(String)) } - def address_state=(_address_state); end - # Attribute for param field address_zip - sig { returns(T.nilable(String)) } - def address_zip; end - sig { params(_address_zip: T.nilable(String)).returns(T.nilable(String)) } - def address_zip=(_address_zip); end - # Attribute for param field currency - sig { returns(T.nilable(String)) } - def currency; end - sig { params(_currency: T.nilable(String)).returns(T.nilable(String)) } - def currency=(_currency); end - # Attribute for param field cvc - sig { returns(T.nilable(String)) } - def cvc; end - sig { params(_cvc: T.nilable(String)).returns(T.nilable(String)) } - def cvc=(_cvc); end - # Attribute for param field exp_month - sig { returns(Integer) } - def exp_month; end - sig { params(_exp_month: Integer).returns(Integer) } - def exp_month=(_exp_month); end - # Attribute for param field exp_year - sig { returns(Integer) } - def exp_year; end - sig { params(_exp_year: Integer).returns(Integer) } - def exp_year=(_exp_year); end - # Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. - sig { returns(T.nilable(T::Hash[String, String])) } - def metadata; end - sig { - params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) - } - def metadata=(_metadata); end - # Attribute for param field name - sig { returns(T.nilable(String)) } - def name; end - sig { params(_name: T.nilable(String)).returns(T.nilable(String)) } - def name=(_name); end - # Attribute for param field number - sig { returns(String) } - def number; end - sig { params(_number: String).returns(String) } - def number=(_number); end - sig { - params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), number: String).void - } - def initialize( - object: nil, - address_city: nil, - address_country: nil, - address_line1: nil, - address_line2: nil, - address_state: nil, - address_zip: nil, - currency: nil, - cvc: nil, - exp_month: nil, - exp_year: nil, - metadata: nil, - name: nil, - number: nil - ); end - end - class CardToken < ::Stripe::RequestParams - # Attribute for param field object - sig { returns(String) } - def object; end - sig { params(_object: String).returns(String) } - def object=(_object); end - # Attribute for param field currency - sig { returns(T.nilable(String)) } - def currency; end - sig { params(_currency: T.nilable(String)).returns(T.nilable(String)) } - def currency=(_currency); end - # Attribute for param field token - sig { returns(String) } - def token; end - sig { params(_token: String).returns(String) } - def token=(_token); end - sig { params(object: String, currency: T.nilable(String), token: String).void } - def initialize(object: nil, currency: nil, token: nil); end - end - # When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency. - sig { returns(T.nilable(T::Boolean)) } - def default_for_currency; end - sig { params(_default_for_currency: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } - def default_for_currency=(_default_for_currency); end - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - # Either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary containing a user’s external account details (with the options shown below). - sig { - returns(T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken)) - } - def external_account; end - sig { - params(_external_account: T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken)).returns(T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken)) - } - def external_account=(_external_account); end - # Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. - sig { returns(T.nilable(T::Hash[String, String])) } - def metadata; end - sig { - params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) - } - def metadata=(_metadata); end - sig { - params(default_for_currency: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), external_account: T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken), metadata: T.nilable(T::Hash[String, String])).void - } - def initialize( - default_for_currency: nil, - expand: nil, - external_account: nil, - metadata: nil - ); end - end -end -# typed: true -module Stripe - class FileRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end -end -# typed: true -module Stripe - class FileLinkRetrieveParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end - end -end -# typed: true -module Stripe - module FinancialConnections - class AccountRetrieveParams < ::Stripe::RequestParams + module DelegatedCheckout + class RequestedSessionRetrieveParams < ::Stripe::RequestParams # Specifies which fields in the response should be expanded. sig { returns(T.nilable(T::Array[String])) } def expand; end @@ -244113,27 +245574,593 @@ module Stripe end # typed: true module Stripe - module FinancialConnections - class AccountRefreshParams < ::Stripe::RequestParams - # Specifies which fields in the response should be expanded. - sig { returns(T.nilable(T::Array[String])) } - def expand; end - sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } - def expand=(_expand); end - # The list of account features that you would like to refresh. - sig { returns(T::Array[String]) } - def features; end - sig { params(_features: T::Array[String]).returns(T::Array[String]) } - def features=(_features); end - sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void } - def initialize(expand: nil, features: nil); end - end - end -end -# typed: true -module Stripe - module FinancialConnections - class AccountInferredBalanceListParams < ::Stripe::RequestParams + module DelegatedCheckout + class RequestedSessionOrderListParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + sig { returns(T.nilable(String)) } + def ending_before; end + sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } + def ending_before=(_ending_before); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + sig { returns(T.nilable(String)) } + def starting_after; end + sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } + def starting_after=(_starting_after); end + sig { + params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void + } + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end + end + end +end +# typed: true +module Stripe + class DisputeRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end +end +# typed: true +module Stripe + module Entitlements + class ActiveEntitlementRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end + end +end +# typed: true +module Stripe + module Entitlements + class FeatureRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end + end +end +# typed: true +module Stripe + class EphemeralKeyCreateParams < ::Stripe::RequestParams + # The ID of the Customer you'd like to modify using the resulting ephemeral key. + sig { returns(T.nilable(String)) } + def customer; end + sig { params(_customer: T.nilable(String)).returns(T.nilable(String)) } + def customer=(_customer); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # The ID of the Issuing Card you'd like to access using the resulting ephemeral key. + sig { returns(T.nilable(String)) } + def issuing_card; end + sig { params(_issuing_card: T.nilable(String)).returns(T.nilable(String)) } + def issuing_card=(_issuing_card); end + # A single-use token, created by Stripe.js, used for creating ephemeral keys for Issuing Cards without exchanging sensitive information. + sig { returns(T.nilable(String)) } + def nonce; end + sig { params(_nonce: T.nilable(String)).returns(T.nilable(String)) } + def nonce=(_nonce); end + # The ID of the Identity VerificationSession you'd like to access using the resulting ephemeral key + sig { returns(T.nilable(String)) } + def verification_session; end + sig { params(_verification_session: T.nilable(String)).returns(T.nilable(String)) } + def verification_session=(_verification_session); end + sig { + params(customer: T.nilable(String), expand: T.nilable(T::Array[String]), issuing_card: T.nilable(String), nonce: T.nilable(String), verification_session: T.nilable(String)).void + } + def initialize( + customer: nil, + expand: nil, + issuing_card: nil, + nonce: nil, + verification_session: nil + ); end + end +end +# typed: true +module Stripe + class EventRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end +end +# typed: true +module Stripe + class ExchangeRateRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end +end +# typed: true +module Stripe + class ExternalAccountDeleteParams < ::Stripe::RequestParams; end +end +# typed: true +module Stripe + class ExternalAccountRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end +end +# typed: true +module Stripe + class ExternalAccountUpdateParams < ::Stripe::RequestParams + class Documents < ::Stripe::RequestParams + class BankAccountOwnershipVerification < ::Stripe::RequestParams + # One or more document ids returned by a [file upload](https://api.stripe.com#create_file) with a `purpose` value of `account_requirement`. + sig { returns(T.nilable(T::Array[String])) } + def files; end + sig { params(_files: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def files=(_files); end + sig { params(files: T.nilable(T::Array[String])).void } + def initialize(files: nil); end + end + # One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check. + sig { + returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)) + } + def bank_account_ownership_verification; end + sig { + params(_bank_account_ownership_verification: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)).returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)) + } + def bank_account_ownership_verification=(_bank_account_ownership_verification); end + sig { + params(bank_account_ownership_verification: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents::BankAccountOwnershipVerification)).void + } + def initialize(bank_account_ownership_verification: nil); end + end + # The name of the person or business that owns the bank account. + sig { returns(T.nilable(String)) } + def account_holder_name; end + sig { params(_account_holder_name: T.nilable(String)).returns(T.nilable(String)) } + def account_holder_name=(_account_holder_name); end + # The type of entity that holds the account. This can be either `individual` or `company`. + sig { returns(T.nilable(T.any(String, String))) } + def account_holder_type; end + sig { + params(_account_holder_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } + def account_holder_type=(_account_holder_type); end + # The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`. + sig { returns(T.nilable(String)) } + def account_type; end + sig { params(_account_type: T.nilable(String)).returns(T.nilable(String)) } + def account_type=(_account_type); end + # City/District/Suburb/Town/Village. + sig { returns(T.nilable(String)) } + def address_city; end + sig { params(_address_city: T.nilable(String)).returns(T.nilable(String)) } + def address_city=(_address_city); end + # Billing address country, if provided when creating card. + sig { returns(T.nilable(String)) } + def address_country; end + sig { params(_address_country: T.nilable(String)).returns(T.nilable(String)) } + def address_country=(_address_country); end + # Address line 1 (Street address/PO Box/Company name). + sig { returns(T.nilable(String)) } + def address_line1; end + sig { params(_address_line1: T.nilable(String)).returns(T.nilable(String)) } + def address_line1=(_address_line1); end + # Address line 2 (Apartment/Suite/Unit/Building). + sig { returns(T.nilable(String)) } + def address_line2; end + sig { params(_address_line2: T.nilable(String)).returns(T.nilable(String)) } + def address_line2=(_address_line2); end + # State/County/Province/Region. + sig { returns(T.nilable(String)) } + def address_state; end + sig { params(_address_state: T.nilable(String)).returns(T.nilable(String)) } + def address_state=(_address_state); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def address_zip; end + sig { params(_address_zip: T.nilable(String)).returns(T.nilable(String)) } + def address_zip=(_address_zip); end + # When set to true, this becomes the default external account for its currency. + sig { returns(T.nilable(T::Boolean)) } + def default_for_currency; end + sig { params(_default_for_currency: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def default_for_currency=(_default_for_currency); end + # Documents that may be submitted to satisfy various informational requests. + sig { returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents)) } + def documents; end + sig { + params(_documents: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents)).returns(T.nilable(::Stripe::ExternalAccountUpdateParams::Documents)) + } + def documents=(_documents); end + # Two digit number representing the card’s expiration month. + sig { returns(T.nilable(String)) } + def exp_month; end + sig { params(_exp_month: T.nilable(String)).returns(T.nilable(String)) } + def exp_month=(_exp_month); end + # Four digit number representing the card’s expiration year. + sig { returns(T.nilable(String)) } + def exp_year; end + sig { params(_exp_year: T.nilable(String)).returns(T.nilable(String)) } + def exp_year=(_exp_year); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. + sig { returns(T.nilable(T.any(String, T::Hash[String, String]))) } + def metadata; end + sig { + params(_metadata: T.nilable(T.any(String, T::Hash[String, String]))).returns(T.nilable(T.any(String, T::Hash[String, String]))) + } + def metadata=(_metadata); end + # Cardholder name. + sig { returns(T.nilable(String)) } + def name; end + sig { params(_name: T.nilable(String)).returns(T.nilable(String)) } + def name=(_name); end + sig { + params(account_holder_name: T.nilable(String), account_holder_type: T.nilable(T.any(String, String)), account_type: T.nilable(String), address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), default_for_currency: T.nilable(T::Boolean), documents: T.nilable(::Stripe::ExternalAccountUpdateParams::Documents), exp_month: T.nilable(String), exp_year: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.any(String, T::Hash[String, String])), name: T.nilable(String)).void + } + def initialize( + account_holder_name: nil, + account_holder_type: nil, + account_type: nil, + address_city: nil, + address_country: nil, + address_line1: nil, + address_line2: nil, + address_state: nil, + address_zip: nil, + default_for_currency: nil, + documents: nil, + exp_month: nil, + exp_year: nil, + expand: nil, + metadata: nil, + name: nil + ); end + end +end +# typed: true +module Stripe + class ExternalAccountListParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + sig { returns(T.nilable(String)) } + def ending_before; end + sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } + def ending_before=(_ending_before); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # Filter external accounts according to a particular object type. + sig { returns(T.nilable(String)) } + def object; end + sig { params(_object: T.nilable(String)).returns(T.nilable(String)) } + def object=(_object); end + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + sig { returns(T.nilable(String)) } + def starting_after; end + sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } + def starting_after=(_starting_after); end + sig { + params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), object: T.nilable(String), starting_after: T.nilable(String)).void + } + def initialize( + ending_before: nil, + expand: nil, + limit: nil, + object: nil, + starting_after: nil + ); end + end +end +# typed: true +module Stripe + class ExternalAccountCreateParams < ::Stripe::RequestParams + class BankAccount < ::Stripe::RequestParams + # Attribute for param field object + sig { returns(String) } + def object; end + sig { params(_object: String).returns(String) } + def object=(_object); end + # The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object. + sig { returns(T.nilable(String)) } + def account_holder_name; end + sig { params(_account_holder_name: T.nilable(String)).returns(T.nilable(String)) } + def account_holder_name=(_account_holder_name); end + # The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object. + sig { returns(T.nilable(String)) } + def account_holder_type; end + sig { params(_account_holder_type: T.nilable(String)).returns(T.nilable(String)) } + def account_holder_type=(_account_holder_type); end + # The account number for the bank account, in string form. Must be a checking account. + sig { returns(String) } + def account_number; end + sig { params(_account_number: String).returns(String) } + def account_number=(_account_number); end + # The country in which the bank account is located. + sig { returns(String) } + def country; end + sig { params(_country: String).returns(String) } + def country=(_country); end + # The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts) + sig { returns(T.nilable(String)) } + def currency; end + sig { params(_currency: T.nilable(String)).returns(T.nilable(String)) } + def currency=(_currency); end + # The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required. + sig { returns(T.nilable(String)) } + def routing_number; end + sig { params(_routing_number: T.nilable(String)).returns(T.nilable(String)) } + def routing_number=(_routing_number); end + sig { + params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void + } + def initialize( + object: nil, + account_holder_name: nil, + account_holder_type: nil, + account_number: nil, + country: nil, + currency: nil, + routing_number: nil + ); end + end + class Card < ::Stripe::RequestParams + # Attribute for param field object + sig { returns(String) } + def object; end + sig { params(_object: String).returns(String) } + def object=(_object); end + # Attribute for param field address_city + sig { returns(T.nilable(String)) } + def address_city; end + sig { params(_address_city: T.nilable(String)).returns(T.nilable(String)) } + def address_city=(_address_city); end + # Attribute for param field address_country + sig { returns(T.nilable(String)) } + def address_country; end + sig { params(_address_country: T.nilable(String)).returns(T.nilable(String)) } + def address_country=(_address_country); end + # Attribute for param field address_line1 + sig { returns(T.nilable(String)) } + def address_line1; end + sig { params(_address_line1: T.nilable(String)).returns(T.nilable(String)) } + def address_line1=(_address_line1); end + # Attribute for param field address_line2 + sig { returns(T.nilable(String)) } + def address_line2; end + sig { params(_address_line2: T.nilable(String)).returns(T.nilable(String)) } + def address_line2=(_address_line2); end + # Attribute for param field address_state + sig { returns(T.nilable(String)) } + def address_state; end + sig { params(_address_state: T.nilable(String)).returns(T.nilable(String)) } + def address_state=(_address_state); end + # Attribute for param field address_zip + sig { returns(T.nilable(String)) } + def address_zip; end + sig { params(_address_zip: T.nilable(String)).returns(T.nilable(String)) } + def address_zip=(_address_zip); end + # Attribute for param field currency + sig { returns(T.nilable(String)) } + def currency; end + sig { params(_currency: T.nilable(String)).returns(T.nilable(String)) } + def currency=(_currency); end + # Attribute for param field cvc + sig { returns(T.nilable(String)) } + def cvc; end + sig { params(_cvc: T.nilable(String)).returns(T.nilable(String)) } + def cvc=(_cvc); end + # Attribute for param field exp_month + sig { returns(Integer) } + def exp_month; end + sig { params(_exp_month: Integer).returns(Integer) } + def exp_month=(_exp_month); end + # Attribute for param field exp_year + sig { returns(Integer) } + def exp_year; end + sig { params(_exp_year: Integer).returns(Integer) } + def exp_year=(_exp_year); end + # Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # Attribute for param field name + sig { returns(T.nilable(String)) } + def name; end + sig { params(_name: T.nilable(String)).returns(T.nilable(String)) } + def name=(_name); end + # Attribute for param field number + sig { returns(String) } + def number; end + sig { params(_number: String).returns(String) } + def number=(_number); end + sig { + params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), number: String).void + } + def initialize( + object: nil, + address_city: nil, + address_country: nil, + address_line1: nil, + address_line2: nil, + address_state: nil, + address_zip: nil, + currency: nil, + cvc: nil, + exp_month: nil, + exp_year: nil, + metadata: nil, + name: nil, + number: nil + ); end + end + class CardToken < ::Stripe::RequestParams + # Attribute for param field object + sig { returns(String) } + def object; end + sig { params(_object: String).returns(String) } + def object=(_object); end + # Attribute for param field currency + sig { returns(T.nilable(String)) } + def currency; end + sig { params(_currency: T.nilable(String)).returns(T.nilable(String)) } + def currency=(_currency); end + # Attribute for param field token + sig { returns(String) } + def token; end + sig { params(_token: String).returns(String) } + def token=(_token); end + sig { params(object: String, currency: T.nilable(String), token: String).void } + def initialize(object: nil, currency: nil, token: nil); end + end + # When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency. + sig { returns(T.nilable(T::Boolean)) } + def default_for_currency; end + sig { params(_default_for_currency: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def default_for_currency=(_default_for_currency); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # Either a token, like the ones returned by [Stripe.js](https://docs.stripe.com/js), or a dictionary containing a user’s external account details (with the options shown below). + sig { + returns(T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken)) + } + def external_account; end + sig { + params(_external_account: T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken)).returns(T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken)) + } + def external_account=(_external_account); end + # Set of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + sig { + params(default_for_currency: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), external_account: T.any(String, ::Stripe::ExternalAccountCreateParams::Card, ::Stripe::ExternalAccountCreateParams::BankAccount, ::Stripe::ExternalAccountCreateParams::CardToken), metadata: T.nilable(T::Hash[String, String])).void + } + def initialize( + default_for_currency: nil, + expand: nil, + external_account: nil, + metadata: nil + ); end + end +end +# typed: true +module Stripe + class FileRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end +end +# typed: true +module Stripe + class FileLinkRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end +end +# typed: true +module Stripe + module FinancialConnections + class AccountRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end + end +end +# typed: true +module Stripe + module FinancialConnections + class AccountRefreshParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # The list of account features that you would like to refresh. + sig { returns(T::Array[String]) } + def features; end + sig { params(_features: T::Array[String]).returns(T::Array[String]) } + def features=(_features); end + sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void } + def initialize(expand: nil, features: nil); end + end + end +end +# typed: true +module Stripe + module FinancialConnections + class AccountInferredBalanceListParams < ::Stripe::RequestParams # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. sig { returns(T.nilable(String)) } def ending_before; end @@ -244758,7 +246785,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # The payment location for which the capability enables functionality. + # The payment location that the capability enables functionality for. sig { returns(String) } def location; end sig { params(_location: String).returns(String) } @@ -253622,6 +255649,2159 @@ module Stripe end end # typed: true +module Stripe + module V2 + module Billing + class ContractListParams < ::Stripe::RequestParams + # Filter by customer ID. + sig { returns(T.nilable(String)) } + def customer; end + sig { params(_customer: T.nilable(String)).returns(T.nilable(String)) } + def customer=(_customer); end + # The limit for the number of results per page. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + sig { params(customer: T.nilable(String), limit: T.nilable(Integer)).void } + def initialize(customer: nil, limit: nil); end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + class ContractCreateParams < ::Stripe::RequestParams + class BillingSettings < ::Stripe::RequestParams + class ContractBillingDetails < ::Stripe::RequestParams + class BillSettingsDetails < ::Stripe::RequestParams + class Calculation < ::Stripe::RequestParams + class Tax < ::Stripe::RequestParams + # The type of tax calculation. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(type: String).void } + def initialize(type: nil); end + end + # Tax calculation settings. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)) + } + def tax; end + sig { + params(_tax: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)) + } + def tax=(_tax); end + sig { + params(tax: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)).void + } + def initialize(tax: nil); end + end + class Invoice < ::Stripe::RequestParams + class TimeUntilDue < ::Stripe::RequestParams + # The interval unit. + sig { returns(String) } + def interval; end + sig { params(_interval: String).returns(String) } + def interval=(_interval); end + # The number of intervals. + sig { returns(Integer) } + def interval_count; end + sig { params(_interval_count: Integer).returns(Integer) } + def interval_count=(_interval_count); end + sig { params(interval: String, interval_count: Integer).void } + def initialize(interval: nil, interval_count: nil); end + end + # The number of time units before the invoice is past due. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)) + } + def time_until_due; end + sig { + params(_time_until_due: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)) + } + def time_until_due=(_time_until_due); end + sig { + params(time_until_due: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)).void + } + def initialize(time_until_due: nil); end + end + # Calculation settings. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation)) + } + def calculation; end + sig { + params(_calculation: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation)) + } + def calculation=(_calculation); end + # Invoice settings. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)) + } + def invoice; end + sig { + params(_invoice: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)) + } + def invoice=(_invoice); end + sig { + params(calculation: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation), invoice: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)).void + } + def initialize(calculation: nil, invoice: nil); end + end + class BillingProfileDetails < ::Stripe::RequestParams + # The customer who pays for the contract invoice. + sig { returns(String) } + def customer; end + sig { params(_customer: String).returns(String) } + def customer=(_customer); end + # The default payment method for the contract. + sig { returns(T.nilable(String)) } + def default_payment_method; end + sig { params(_default_payment_method: T.nilable(String)).returns(T.nilable(String)) } + def default_payment_method=(_default_payment_method); end + sig { params(customer: String, default_payment_method: T.nilable(String)).void } + def initialize(customer: nil, default_payment_method: nil); end + end + class CollectionSettingsDetails < ::Stripe::RequestParams + # The collection method. + sig { returns(String) } + def collection_method; end + sig { params(_collection_method: String).returns(String) } + def collection_method=(_collection_method); end + # The payment method configuration. + sig { returns(T.nilable(String)) } + def payment_method_configuration; end + sig { + params(_payment_method_configuration: T.nilable(String)).returns(T.nilable(String)) + } + def payment_method_configuration=(_payment_method_configuration); end + sig { + params(collection_method: String, payment_method_configuration: T.nilable(String)).void + } + def initialize(collection_method: nil, payment_method_configuration: nil); end + end + # The bill settings details. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails)) + } + def bill_settings_details; end + sig { + params(_bill_settings_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails)) + } + def bill_settings_details=(_bill_settings_details); end + # The billing profile details. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails) + } + def billing_profile_details; end + sig { + params(_billing_profile_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails).returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails) + } + def billing_profile_details=(_billing_profile_details); end + # The collection settings details. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails) + } + def collection_settings_details; end + sig { + params(_collection_settings_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails).returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails) + } + def collection_settings_details=(_collection_settings_details); end + sig { + params(bill_settings_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails), billing_profile_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails, collection_settings_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails).void + } + def initialize( + bill_settings_details: nil, + billing_profile_details: nil, + collection_settings_details: nil + ); end + end + # Billing settings details for the contract. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)) + } + def contract_billing_details; end + sig { + params(_contract_billing_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)) + } + def contract_billing_details=(_contract_billing_details); end + sig { + params(contract_billing_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)).void + } + def initialize(contract_billing_details: nil); end + end + class ContractLine < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + class Override < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + class ServiceAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class CreditGrant < ::Stripe::RequestParams + class Amount < ::Stripe::RequestParams + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + sig { + params(_monetary: T.nilable(::Stripe::V2::Amount)).returns(T.nilable(::Stripe::V2::Amount)) + } + def monetary=(_monetary); end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(monetary: T.nilable(::Stripe::V2::Amount), type: String).void } + def initialize(monetary: nil, type: nil); end + end + class ApplicabilityConfig < ::Stripe::RequestParams + class Scope < ::Stripe::RequestParams + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + sig { + params(_billable_items: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) + } + def billable_items=(_billable_items); end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + sig { params(_price_type: T.nilable(String)).returns(T.nilable(String)) } + def price_type=(_price_type); end + sig { + params(billable_items: T.nilable(T::Array[String]), price_type: T.nilable(String)).void + } + def initialize(billable_items: nil, price_type: nil); end + end + # The applicability scope of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope) + } + def scope; end + sig { + params(_scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope) + } + def scope=(_scope); end + sig { + params(scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope).void + } + def initialize(scope: nil); end + end + class ExpiryConfig < ::Stripe::RequestParams + # The type of the expiry configuration. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(type: String).void } + def initialize(type: nil); end + end + # The amount of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount) + } + def amount; end + sig { + params(_amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount) + } + def amount=(_amount); end + # Defines the scope where the credit grant is applicable. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig) + } + def applicability_config; end + sig { + params(_applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig) + } + def applicability_config=(_applicability_config); end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + sig { params(_category: T.nilable(String)).returns(T.nilable(String)) } + def category=(_category); end + # The expiry configuration for the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig) + } + def expiry_config; end + sig { + params(_expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig) + } + def expiry_config=(_expiry_config); end + # A descriptive name. + sig { returns(String) } + def name; end + sig { params(_name: String).returns(String) } + def name=(_name); end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + sig { params(_priority: T.nilable(Integer)).returns(T.nilable(Integer)) } + def priority=(_priority); end + sig { + params(amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount, applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig, category: T.nilable(String), expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig, name: String, priority: T.nilable(Integer)).void + } + def initialize( + amount: nil, + applicability_config: nil, + category: nil, + expiry_config: nil, + name: nil, + priority: nil + ); end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant)) + } + def credit_grant; end + sig { + params(_credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant)) + } + def credit_grant=(_credit_grant); end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + sig { params(_service_interval: String).returns(String) } + def service_interval=(_service_interval); end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + sig { params(_service_interval_count: Integer).returns(Integer) } + def service_interval_count=(_service_interval_count); end + # The type of the service action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant), service_interval: String, service_interval_count: Integer, type: String).void + } + def initialize( + credit_grant: nil, + service_interval: nil, + service_interval_count: nil, + type: nil + ); end + end + class Replace < ::Stripe::RequestParams + class CreditGrant < ::Stripe::RequestParams + class Amount < ::Stripe::RequestParams + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + sig { + params(_monetary: T.nilable(::Stripe::V2::Amount)).returns(T.nilable(::Stripe::V2::Amount)) + } + def monetary=(_monetary); end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(monetary: T.nilable(::Stripe::V2::Amount), type: String).void } + def initialize(monetary: nil, type: nil); end + end + class ApplicabilityConfig < ::Stripe::RequestParams + class Scope < ::Stripe::RequestParams + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + sig { + params(_billable_items: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) + } + def billable_items=(_billable_items); end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + sig { params(_price_type: T.nilable(String)).returns(T.nilable(String)) } + def price_type=(_price_type); end + sig { + params(billable_items: T.nilable(T::Array[String]), price_type: T.nilable(String)).void + } + def initialize(billable_items: nil, price_type: nil); end + end + # The applicability scope of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope) + } + def scope; end + sig { + params(_scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope) + } + def scope=(_scope); end + sig { + params(scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope).void + } + def initialize(scope: nil); end + end + class ExpiryConfig < ::Stripe::RequestParams + # The type of the expiry configuration. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(type: String).void } + def initialize(type: nil); end + end + # The amount of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount) + } + def amount; end + sig { + params(_amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount) + } + def amount=(_amount); end + # Defines the scope where the credit grant is applicable. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig) + } + def applicability_config; end + sig { + params(_applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig) + } + def applicability_config=(_applicability_config); end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + sig { params(_category: T.nilable(String)).returns(T.nilable(String)) } + def category=(_category); end + # The expiry configuration for the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig) + } + def expiry_config; end + sig { + params(_expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig) + } + def expiry_config=(_expiry_config); end + # A descriptive name. + sig { returns(String) } + def name; end + sig { params(_name: String).returns(String) } + def name=(_name); end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + sig { params(_priority: T.nilable(Integer)).returns(T.nilable(Integer)) } + def priority=(_priority); end + sig { + params(amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount, applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig, category: T.nilable(String), expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig, name: String, priority: T.nilable(Integer)).void + } + def initialize( + amount: nil, + applicability_config: nil, + category: nil, + expiry_config: nil, + name: nil, + priority: nil + ); end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant)) + } + def credit_grant; end + sig { + params(_credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant)) + } + def credit_grant=(_credit_grant); end + # The ID of the service action to replace. + sig { returns(T.nilable(String)) } + def id; end + sig { params(_id: T.nilable(String)).returns(T.nilable(String)) } + def id=(_id); end + # The lookup key for the service action to replace. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + sig { params(_service_interval: String).returns(String) } + def service_interval=(_service_interval); end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + sig { params(_service_interval_count: Integer).returns(Integer) } + def service_interval_count=(_service_interval_count); end + # The type of the service action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant), id: T.nilable(String), lookup_key: T.nilable(String), service_interval: String, service_interval_count: Integer, type: String).void + } + def initialize( + credit_grant: nil, + id: nil, + lookup_key: nil, + service_interval: nil, + service_interval_count: nil, + type: nil + ); end + end + # Parameters for adding a new service action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add)) + } + def add; end + sig { + params(_add: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add)) + } + def add=(_add); end + # Parameters for replacing an existing service action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace)) + } + def replace; end + sig { + params(_replace: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace)) + } + def replace=(_replace); end + # The type of service action override. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(add: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add), replace: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace), type: String).void + } + def initialize(add: nil, replace: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + # Timestamp to indicate when the override ends. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt) + } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt) + } + def ends_at=(_ends_at); end + # Service action override parameters. Required if `type` is `service_action`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction)) + } + def service_action; end + sig { + params(_service_action: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction)) + } + def service_action=(_service_action); end + # Timestamp to indicate when the override starts. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt) + } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt) + } + def starts_at=(_starts_at); end + # The type of the override. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt, service_action: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction), starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt, type: String).void + } + def initialize(ends_at: nil, service_action: nil, starts_at: nil, type: nil); end + end + class Pricing < ::Stripe::RequestParams; end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + # Timestamp to indicate when the contract line ends. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt) } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt) + } + def ends_at=(_ends_at); end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # List of overrides. Later overrides in the list override earlier ones. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override]) + } + def overrides; end + sig { + params(_overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override]) + } + def overrides=(_overrides); end + # The pricing configuration for the contract line. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing) } + def pricing; end + sig { + params(_pricing: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing) + } + def pricing=(_pricing); end + # Timestamp to indicate when the contract line starts. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt) } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt, metadata: T.nilable(T::Hash[String, String]), overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override], pricing: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing, starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt).void + } + def initialize( + ends_at: nil, + metadata: nil, + overrides: nil, + pricing: nil, + starts_at: nil + ); end + end + class LicenseQuantityAction < ::Stripe::RequestParams + class EffectiveAt < ::Stripe::RequestParams + # The timestamp for the effective at. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the effective at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Set < ::Stripe::RequestParams + # The quantity to set. + sig { returns(Integer) } + def quantity; end + sig { params(_quantity: Integer).returns(Integer) } + def quantity=(_quantity); end + sig { params(quantity: Integer).void } + def initialize(quantity: nil); end + end + # The effective at for the license quantity action. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at; end + sig { + params(_effective_at: ::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt).returns(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at=(_effective_at); end + # The ID of the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_id; end + sig { params(_license_pricing_id: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_id=(_license_pricing_id); end + # The lookup key for the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_lookup_key; end + sig { params(_license_pricing_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_lookup_key=(_license_pricing_lookup_key); end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + sig { params(_license_pricing_type: String).returns(String) } + def license_pricing_type=(_license_pricing_type); end + # The pricing line for the license quantity action. + sig { returns(T.nilable(String)) } + def pricing_line; end + sig { params(_pricing_line: T.nilable(String)).returns(T.nilable(String)) } + def pricing_line=(_pricing_line); end + # The set quantity for the license quantity action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set)) + } + def set; end + sig { + params(_set: T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set)) + } + def set=(_set); end + # The type of the license quantity action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(effective_at: ::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt, license_pricing_id: T.nilable(String), license_pricing_lookup_key: T.nilable(String), license_pricing_type: String, pricing_line: T.nilable(String), set: T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set), type: String).void + } + def initialize( + effective_at: nil, + license_pricing_id: nil, + license_pricing_lookup_key: nil, + license_pricing_type: nil, + pricing_line: nil, + set: nil, + type: nil + ); end + end + class OneTimeFee < ::Stripe::RequestParams + class BillSchedule < ::Stripe::RequestParams + class BillAt < ::Stripe::RequestParams + # The datetime at which the entry should be billed. Required if `type` is `datetime`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the bill_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # When this entry should be billed. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt) + } + def bill_at; end + sig { + params(_bill_at: ::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt).returns(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt) + } + def bill_at=(_bill_at); end + # The amount to bill for this entry, in the smallest currency unit. + sig { returns(Integer) } + def value; end + sig { params(_value: Integer).returns(Integer) } + def value=(_value); end + sig { + params(bill_at: ::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt, value: Integer).void + } + def initialize(bill_at: nil, value: nil); end + def self.field_encodings + @field_encodings = {value: :int64_string} + end + end + class ProductDetails < ::Stripe::RequestParams + # The ID of the v1 Product. + sig { returns(String) } + def product; end + sig { params(_product: String).returns(String) } + def product=(_product); end + sig { params(product: String).void } + def initialize(product: nil); end + end + # The bill schedule for the fee. Each entry produces an individual invoice item billed at `bill_at`. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule]) + } + def bill_schedule; end + sig { + params(_bill_schedule: T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule]) + } + def bill_schedule=(_bill_schedule); end + # The type of billable item that this fee references. + sig { returns(String) } + def billable_item_type; end + sig { params(_billable_item_type: String).returns(String) } + def billable_item_type=(_billable_item_type); end + # Details for a product billable target. Required when `billable_item_type` is `product`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)) + } + def product_details; end + sig { + params(_product_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)) + } + def product_details=(_product_details); end + sig { + params(bill_schedule: T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule], billable_item_type: String, product_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)).void + } + def initialize(bill_schedule: nil, billable_item_type: nil, product_details: nil); end + def self.field_encodings + @field_encodings = { + bill_schedule: { + kind: :array, + element: {kind: :object, fields: {value: :int64_string}}, + }, + } + end + end + class PricingLine < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the ends_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Pricing < ::Stripe::RequestParams + class PriceDetails < ::Stripe::RequestParams + # The ID of the V1 price. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # The quantity for the price. Only applicable for licensed prices. + sig { returns(T.nilable(Integer)) } + def quantity; end + sig { params(_quantity: T.nilable(Integer)).returns(T.nilable(Integer)) } + def quantity=(_quantity); end + sig { params(price: String, quantity: T.nilable(Integer)).void } + def initialize(price: nil, quantity: nil); end + end + # V1 price details. Required if `type` is `price`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails)) + } + def price_details; end + sig { + params(_price_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails)) + } + def price_details=(_price_details); end + # The type of pricing. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(price_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails), type: String).void + } + def initialize(price_details: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the starts_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # When the pricing line ends. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt) } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt) + } + def ends_at=(_ends_at); end + # A user-provided lookup key to reference this pricing line. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # The pricing configuration for the pricing line. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing) } + def pricing; end + sig { + params(_pricing: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing).returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing) + } + def pricing=(_pricing); end + # When the pricing line starts. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt) } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt, lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), pricing: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing, starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + metadata: nil, + pricing: nil, + starts_at: nil + ); end + end + class PricingOverride < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the ends_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Multiplier < ::Stripe::RequestParams + class Criterion < ::Stripe::RequestParams + class MetadataCondition < ::Stripe::RequestParams + class AllOf < ::Stripe::RequestParams + # The metadata key. + sig { returns(String) } + def key; end + sig { params(_key: String).returns(String) } + def key=(_key); end + # The metadata value. + sig { returns(String) } + def value; end + sig { params(_value: String).returns(String) } + def value=(_value); end + sig { params(key: String, value: String).void } + def initialize(key: nil, value: nil); end + end + # All of these key-value conditions must match. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of; end + sig { + params(_all_of: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of=(_all_of); end + sig { + params(all_of: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]).void + } + def initialize(all_of: nil); end + end + # Filter by billable item IDs. + sig { returns(T::Array[String]) } + def billable_item_ids; end + sig { params(_billable_item_ids: T::Array[String]).returns(T::Array[String]) } + def billable_item_ids=(_billable_item_ids); end + # Filter by billable item lookup keys. + sig { returns(T::Array[String]) } + def billable_item_lookup_keys; end + sig { params(_billable_item_lookup_keys: T::Array[String]).returns(T::Array[String]) } + def billable_item_lookup_keys=(_billable_item_lookup_keys); end + # Filter by billable item type. + sig { returns(T::Array[String]) } + def billable_item_types; end + sig { params(_billable_item_types: T::Array[String]).returns(T::Array[String]) } + def billable_item_types=(_billable_item_types); end + # Filter by metadata conditions. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions; end + sig { + params(_metadata_conditions: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions=(_metadata_conditions); end + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + sig { returns(T::Array[String]) } + def rate_card_ids; end + sig { params(_rate_card_ids: T::Array[String]).returns(T::Array[String]) } + def rate_card_ids=(_rate_card_ids); end + # Whether to include or exclude items matching these criteria. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(billable_item_ids: T::Array[String], billable_item_lookup_keys: T::Array[String], billable_item_types: T::Array[String], metadata_conditions: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition], rate_card_ids: T::Array[String], type: String).void + } + def initialize( + billable_item_ids: nil, + billable_item_lookup_keys: nil, + billable_item_types: nil, + metadata_conditions: nil, + rate_card_ids: nil, + type: nil + ); end + end + # Criteria determining which rates the multiplier applies to. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion]) + } + def criteria; end + sig { + params(_criteria: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion]) + } + def criteria=(_criteria); end + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + sig { returns(String) } + def factor; end + sig { params(_factor: String).returns(String) } + def factor=(_factor); end + sig { + params(criteria: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion], factor: String).void + } + def initialize(criteria: nil, factor: nil); end + end + class OverwritePrice < ::Stripe::RequestParams + class Tier < ::Stripe::RequestParams + # Price for the entire tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def flat_amount; end + sig { params(_flat_amount: T.nilable(String)).returns(T.nilable(String)) } + def flat_amount=(_flat_amount); end + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + # Up to and including this quantity will be contained in the tier. + sig { returns(T.nilable(BigDecimal)) } + def up_to_decimal; end + sig { params(_up_to_decimal: T.nilable(BigDecimal)).returns(T.nilable(BigDecimal)) } + def up_to_decimal=(_up_to_decimal); end + # No upper bound to this tier. + sig { returns(T.nilable(String)) } + def up_to_inf; end + sig { params(_up_to_inf: T.nilable(String)).returns(T.nilable(String)) } + def up_to_inf=(_up_to_inf); end + sig { + params(flat_amount: T.nilable(String), unit_amount: T.nilable(String), up_to_decimal: T.nilable(BigDecimal), up_to_inf: T.nilable(String)).void + } + def initialize( + flat_amount: nil, + unit_amount: nil, + up_to_decimal: nil, + up_to_inf: nil + ); end + def self.field_encodings + @field_encodings = {up_to_decimal: :decimal_string} + end + end + # The ID of the V1 price to overwrite. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # Defines whether the tiered price should be graduated or volume-based. + sig { returns(T.nilable(String)) } + def tiering_mode; end + sig { params(_tiering_mode: T.nilable(String)).returns(T.nilable(String)) } + def tiering_mode=(_tiering_mode); end + # Each element represents a pricing tier. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier])) + } + def tiers; end + sig { + params(_tiers: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier])) + } + def tiers=(_tiers); end + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + sig { + params(price: String, tiering_mode: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier]), unit_amount: T.nilable(String)).void + } + def initialize(price: nil, tiering_mode: nil, tiers: nil, unit_amount: nil); end + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + } + end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the starts_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # When the pricing override ends. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt) } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt) + } + def ends_at=(_ends_at); end + # A user-provided lookup key to reference this pricing override. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # Parameters for a multiplier override. Required if `type` is `multiplier`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier)) + } + def multiplier; end + sig { + params(_multiplier: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier)) + } + def multiplier=(_multiplier); end + # Parameters for an overwrite_price override. Required if `type` is `overwrite_price`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice)) + } + def overwrite_price; end + sig { + params(_overwrite_price: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice)) + } + def overwrite_price=(_overwrite_price); end + # The priority of this override relative to others. Lower number = higher priority. + sig { returns(Integer) } + def priority; end + sig { params(_priority: Integer).returns(Integer) } + def priority=(_priority); end + # When the pricing override starts. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt) } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt) + } + def starts_at=(_starts_at); end + # The type of pricing override. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt, lookup_key: T.nilable(String), multiplier: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier), overwrite_price: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice), priority: Integer, starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt, type: String).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + multiplier: nil, + overwrite_price: nil, + priority: nil, + starts_at: nil, + type: nil + ); end + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + } + end + end + # The billing settings for the contract. + sig { returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings)) } + def billing_settings; end + sig { + params(_billing_settings: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings)) + } + def billing_settings=(_billing_settings); end + # A list of contract lines to create with the contract. + sig { returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine]) } + def contract_lines; end + sig { + params(_contract_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine]) + } + def contract_lines=(_contract_lines); end + # A unique user-provided contract number e.g. C-2026-0001. + sig { returns(String) } + def contract_number; end + sig { params(_contract_number: String).returns(String) } + def contract_number=(_contract_number); end + # Currency of the contract. + sig { returns(String) } + def currency; end + sig { params(_currency: String).returns(String) } + def currency=(_currency); end + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + # A list of license quantity actions to create with the contract. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction]) + } + def license_quantity_actions; end + sig { + params(_license_quantity_actions: T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction]) + } + def license_quantity_actions=(_license_quantity_actions); end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # A list of one-time fees to create with the contract. Each fee is billed as individual invoice items per its bill_schedule. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee])) + } + def one_time_fees; end + sig { + params(_one_time_fees: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee])) + } + def one_time_fees=(_one_time_fees); end + # A list of pricing lines to create with the contract. + sig { returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine]) } + def pricing_lines; end + sig { + params(_pricing_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine]) + } + def pricing_lines=(_pricing_lines); end + # A list of pricing overrides to create with the contract. + sig { returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]) } + def pricing_overrides; end + sig { + params(_pricing_overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]) + } + def pricing_overrides=(_pricing_overrides); end + sig { + params(billing_settings: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings), contract_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine], contract_number: String, currency: String, include: T.nilable(T::Array[String]), license_quantity_actions: T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction], metadata: T.nilable(T::Hash[String, String]), one_time_fees: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee]), pricing_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine], pricing_overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]).void + } + def initialize( + billing_settings: nil, + contract_lines: nil, + contract_number: nil, + currency: nil, + include: nil, + license_quantity_actions: nil, + metadata: nil, + one_time_fees: nil, + pricing_lines: nil, + pricing_overrides: nil + ); end + def self.field_encodings + @field_encodings = { + one_time_fees: { + kind: :array, + element: { + kind: :object, + fields: { + bill_schedule: { + kind: :array, + element: {kind: :object, fields: {value: :int64_string}}, + }, + }, + }, + }, + pricing_overrides: { + kind: :array, + element: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + }, + }, + }, + } + end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + class ContractRetrieveParams < ::Stripe::RequestParams + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + class ContractUpdateParams < ::Stripe::RequestParams + class LicenseQuantityAction < ::Stripe::RequestParams + class EffectiveAt < ::Stripe::RequestParams + # The timestamp for the effective at. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the effective at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Set < ::Stripe::RequestParams + # The quantity to set. + sig { returns(Integer) } + def quantity; end + sig { params(_quantity: Integer).returns(Integer) } + def quantity=(_quantity); end + sig { params(quantity: Integer).void } + def initialize(quantity: nil); end + end + # The effective at for the license quantity action. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at; end + sig { + params(_effective_at: ::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt).returns(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at=(_effective_at); end + # The ID of the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_id; end + sig { params(_license_pricing_id: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_id=(_license_pricing_id); end + # The lookup key for the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_lookup_key; end + sig { params(_license_pricing_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_lookup_key=(_license_pricing_lookup_key); end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + sig { params(_license_pricing_type: String).returns(String) } + def license_pricing_type=(_license_pricing_type); end + # The pricing line ID for the license quantity action. + sig { returns(T.nilable(String)) } + def pricing_line; end + sig { params(_pricing_line: T.nilable(String)).returns(T.nilable(String)) } + def pricing_line=(_pricing_line); end + # The pricing line lookup key for the license quantity action. + sig { returns(T.nilable(String)) } + def pricing_line_lookup_key; end + sig { params(_pricing_line_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def pricing_line_lookup_key=(_pricing_line_lookup_key); end + # The set quantity for the license quantity action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set)) + } + def set; end + sig { + params(_set: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set)) + } + def set=(_set); end + # The type of the license quantity action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(effective_at: ::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt, license_pricing_id: T.nilable(String), license_pricing_lookup_key: T.nilable(String), license_pricing_type: String, pricing_line: T.nilable(String), pricing_line_lookup_key: T.nilable(String), set: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set), type: String).void + } + def initialize( + effective_at: nil, + license_pricing_id: nil, + license_pricing_lookup_key: nil, + license_pricing_type: nil, + pricing_line: nil, + pricing_line_lookup_key: nil, + set: nil, + type: nil + ); end + end + class PricingLineAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Pricing < ::Stripe::RequestParams + class PriceDetails < ::Stripe::RequestParams + # The ID of the V1 price. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # The quantity for the price. Only applicable for licensed prices. + sig { returns(T.nilable(Integer)) } + def quantity; end + sig { params(_quantity: T.nilable(Integer)).returns(T.nilable(Integer)) } + def quantity=(_quantity); end + sig { params(price: String, quantity: T.nilable(Integer)).void } + def initialize(price: nil, quantity: nil); end + end + # V1 price details. Required if `type` is `price`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails)) + } + def price_details; end + sig { + params(_price_details: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails)) + } + def price_details=(_price_details); end + # The type of pricing. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(price_details: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails), type: String).void + } + def initialize(price_details: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The end time for the pricing line. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt) + } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt) + } + def ends_at=(_ends_at); end + # A lookup key for the pricing line. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # Metadata for the pricing line. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # The pricing configuration for the pricing line. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing) + } + def pricing; end + sig { + params(_pricing: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing) + } + def pricing=(_pricing); end + # The start time for the pricing line. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt) + } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt, lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), pricing: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing, starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + metadata: nil, + pricing: nil, + starts_at: nil + ); end + end + class Remove < ::Stripe::RequestParams + # The ID of the pricing line to remove. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + sig { params(id: String).void } + def initialize(id: nil); end + end + class Update < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The updated end time for the pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt)) + } + def ends_at; end + sig { + params(_ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt)) + } + def ends_at=(_ends_at); end + # The ID of the pricing line. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + # The updated start time for the pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)) + } + def starts_at; end + sig { + params(_starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt), id: String, starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)).void + } + def initialize(ends_at: nil, id: nil, starts_at: nil); end + end + # Parameters for adding a pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add)) + } + def add; end + sig { + params(_add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add)) + } + def add=(_add); end + # Parameters for removing a pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove)) + } + def remove; end + sig { + params(_remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove)) + } + def remove=(_remove); end + # The type of pricing line action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + # Parameters for updating a pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)) + } + def update; end + sig { + params(_update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)) + } + def update=(_update); end + sig { + params(add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add), remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove), type: String, update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)).void + } + def initialize(add: nil, remove: nil, type: nil, update: nil); end + end + class PricingOverrideAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Multiplier < ::Stripe::RequestParams + class Criterion < ::Stripe::RequestParams + class MetadataCondition < ::Stripe::RequestParams + class AllOf < ::Stripe::RequestParams + # The metadata key. + sig { returns(String) } + def key; end + sig { params(_key: String).returns(String) } + def key=(_key); end + # The metadata value. + sig { returns(String) } + def value; end + sig { params(_value: String).returns(String) } + def value=(_value); end + sig { params(key: String, value: String).void } + def initialize(key: nil, value: nil); end + end + # All of these key-value conditions must match. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of; end + sig { + params(_all_of: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of=(_all_of); end + sig { + params(all_of: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]).void + } + def initialize(all_of: nil); end + end + # Filter by billable item IDs. + sig { returns(T::Array[String]) } + def billable_item_ids; end + sig { params(_billable_item_ids: T::Array[String]).returns(T::Array[String]) } + def billable_item_ids=(_billable_item_ids); end + # Filter by billable item lookup keys. + sig { returns(T::Array[String]) } + def billable_item_lookup_keys; end + sig { + params(_billable_item_lookup_keys: T::Array[String]).returns(T::Array[String]) + } + def billable_item_lookup_keys=(_billable_item_lookup_keys); end + # Filter by billable item type. + sig { returns(T::Array[String]) } + def billable_item_types; end + sig { params(_billable_item_types: T::Array[String]).returns(T::Array[String]) } + def billable_item_types=(_billable_item_types); end + # Filter by metadata conditions. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions; end + sig { + params(_metadata_conditions: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions=(_metadata_conditions); end + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + sig { returns(T::Array[String]) } + def rate_card_ids; end + sig { params(_rate_card_ids: T::Array[String]).returns(T::Array[String]) } + def rate_card_ids=(_rate_card_ids); end + # Whether to include or exclude items matching these criteria. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(billable_item_ids: T::Array[String], billable_item_lookup_keys: T::Array[String], billable_item_types: T::Array[String], metadata_conditions: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition], rate_card_ids: T::Array[String], type: String).void + } + def initialize( + billable_item_ids: nil, + billable_item_lookup_keys: nil, + billable_item_types: nil, + metadata_conditions: nil, + rate_card_ids: nil, + type: nil + ); end + end + # Criteria determining which rates the multiplier applies to. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion]) + } + def criteria; end + sig { + params(_criteria: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion]) + } + def criteria=(_criteria); end + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + sig { returns(String) } + def factor; end + sig { params(_factor: String).returns(String) } + def factor=(_factor); end + sig { + params(criteria: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion], factor: String).void + } + def initialize(criteria: nil, factor: nil); end + end + class OverwritePrice < ::Stripe::RequestParams + class Tier < ::Stripe::RequestParams + # Price for the entire tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def flat_amount; end + sig { params(_flat_amount: T.nilable(String)).returns(T.nilable(String)) } + def flat_amount=(_flat_amount); end + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + # Up to and including this quantity will be contained in the tier. + sig { returns(T.nilable(BigDecimal)) } + def up_to_decimal; end + sig { params(_up_to_decimal: T.nilable(BigDecimal)).returns(T.nilable(BigDecimal)) } + def up_to_decimal=(_up_to_decimal); end + # No upper bound to this tier. + sig { returns(T.nilable(String)) } + def up_to_inf; end + sig { params(_up_to_inf: T.nilable(String)).returns(T.nilable(String)) } + def up_to_inf=(_up_to_inf); end + sig { + params(flat_amount: T.nilable(String), unit_amount: T.nilable(String), up_to_decimal: T.nilable(BigDecimal), up_to_inf: T.nilable(String)).void + } + def initialize( + flat_amount: nil, + unit_amount: nil, + up_to_decimal: nil, + up_to_inf: nil + ); end + def self.field_encodings + @field_encodings = {up_to_decimal: :decimal_string} + end + end + # The ID of the V1 price to overwrite. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # Defines whether the tiered price should be graduated or volume-based. + sig { returns(T.nilable(String)) } + def tiering_mode; end + sig { params(_tiering_mode: T.nilable(String)).returns(T.nilable(String)) } + def tiering_mode=(_tiering_mode); end + # Each element represents a pricing tier. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier]) + } + def tiers; end + sig { + params(_tiers: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier]) + } + def tiers=(_tiers); end + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + sig { + params(price: String, tiering_mode: T.nilable(String), tiers: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier], unit_amount: T.nilable(String)).void + } + def initialize(price: nil, tiering_mode: nil, tiers: nil, unit_amount: nil); end + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + } + end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The end time for the pricing override. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt) + } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt) + } + def ends_at=(_ends_at); end + # A lookup key for the pricing override. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # A multiplier override to add. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier)) + } + def multiplier; end + sig { + params(_multiplier: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier)) + } + def multiplier=(_multiplier); end + # An overwrite price override to add. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice)) + } + def overwrite_price; end + sig { + params(_overwrite_price: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice)) + } + def overwrite_price=(_overwrite_price); end + # The priority for the pricing override. + sig { returns(Integer) } + def priority; end + sig { params(_priority: Integer).returns(Integer) } + def priority=(_priority); end + # The start time for the pricing override. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt) + } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt) + } + def starts_at=(_starts_at); end + # The type of pricing override to add. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt, lookup_key: T.nilable(String), multiplier: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier), overwrite_price: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice), priority: Integer, starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt, type: String).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + multiplier: nil, + overwrite_price: nil, + priority: nil, + starts_at: nil, + type: nil + ); end + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + } + end + end + class Remove < ::Stripe::RequestParams + # The ID of the pricing override to remove. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + sig { params(id: String).void } + def initialize(id: nil); end + end + class Update < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The updated end time for the pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt)) + } + def ends_at; end + sig { + params(_ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt)) + } + def ends_at=(_ends_at); end + # The ID of the pricing override. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + # The updated start time for the pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)) + } + def starts_at; end + sig { + params(_starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt), id: String, starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)).void + } + def initialize(ends_at: nil, id: nil, starts_at: nil); end + end + # Parameters for adding a pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add)) + } + def add; end + sig { + params(_add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add)) + } + def add=(_add); end + # Parameters for removing a pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove)) + } + def remove; end + sig { + params(_remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove)) + } + def remove=(_remove); end + # The type of pricing override action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + # Parameters for updating a pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)) + } + def update; end + sig { + params(_update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)) + } + def update=(_update); end + sig { + params(add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add), remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove), type: String, update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)).void + } + def initialize(add: nil, remove: nil, type: nil, update: nil); end + def self.field_encodings + @field_encodings = { + add: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + }, + }, + } + end + end + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + # Schema-only: License quantity actions (implementation to follow). + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction])) + } + def license_quantity_actions; end + sig { + params(_license_quantity_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction])) + } + def license_quantity_actions=(_license_quantity_actions); end + # Pricing line actions to apply. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction])) + } + def pricing_line_actions; end + sig { + params(_pricing_line_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction])) + } + def pricing_line_actions=(_pricing_line_actions); end + # Pricing override actions to apply. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])) + } + def pricing_override_actions; end + sig { + params(_pricing_override_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])) + } + def pricing_override_actions=(_pricing_override_actions); end + sig { + params(include: T.nilable(T::Array[String]), license_quantity_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction]), pricing_line_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction]), pricing_override_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])).void + } + def initialize( + include: nil, + license_quantity_actions: nil, + pricing_line_actions: nil, + pricing_override_actions: nil + ); end + def self.field_encodings + @field_encodings = { + pricing_override_actions: { + kind: :array, + element: { + kind: :object, + fields: { + add: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + }, + }, + }, + }, + }, + } + end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + class ContractActivateParams < ::Stripe::RequestParams + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + class ContractCancelParams < ::Stripe::RequestParams + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end + end + end +end +# typed: true +module Stripe + module V2 + module Billing + module Contracts + module LicensePricing + class QuantityChangeListQuantityChangesParams < ::Stripe::RequestParams + # The limit for the number of results per page. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + sig { params(limit: T.nilable(Integer)).void } + def initialize(limit: nil); end + end + end + end + end + end +end +# typed: true module Stripe module V2 module Billing @@ -261083,8 +265263,19 @@ module Stripe def losses_collector; end sig { params(_losses_collector: String).returns(String) } def losses_collector=(_losses_collector); end - sig { params(fees_collector: String, losses_collector: String).void } - def initialize(fees_collector: nil, losses_collector: nil); end + # A value indicating the party responsible for collecting requirements on this account. + sig { returns(T.nilable(String)) } + def requirements_collector; end + sig { params(_requirements_collector: T.nilable(String)).returns(T.nilable(String)) } + def requirements_collector=(_requirements_collector); end + sig { + params(fees_collector: String, losses_collector: String, requirements_collector: T.nilable(String)).void + } + def initialize( + fees_collector: nil, + losses_collector: nil, + requirements_collector: nil + ); end end # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). sig { returns(T.nilable(String)) } @@ -267206,8 +271397,19 @@ module Stripe def losses_collector; end sig { params(_losses_collector: String).returns(String) } def losses_collector=(_losses_collector); end - sig { params(fees_collector: String, losses_collector: String).void } - def initialize(fees_collector: nil, losses_collector: nil); end + # A value indicating the party responsible for collecting requirements on this account. + sig { returns(T.nilable(String)) } + def requirements_collector; end + sig { params(_requirements_collector: T.nilable(String)).returns(T.nilable(String)) } + def requirements_collector=(_requirements_collector); end + sig { + params(fees_collector: String, losses_collector: String, requirements_collector: T.nilable(String)).void + } + def initialize( + fees_collector: nil, + losses_collector: nil, + requirements_collector: nil + ); end end # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). sig { returns(T.nilable(String)) } @@ -276724,7 +280926,15 @@ module Stripe module V2 module Data module Reporting - class QueryRunRetrieveParams < ::Stripe::RequestParams; end + class QueryRunRetrieveParams < ::Stripe::RequestParams + # Any optional includes (see https://docs.stripe.com/api-includable-response-values). + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end end end end @@ -277978,7 +282188,7 @@ module Stripe def recipient_verification; end sig { params(_recipient_verification: T.nilable(String)).returns(T.nilable(String)) } def recipient_verification=(_recipient_verification); end - # The description that appears on the receiving end for an OutboundPayment (for example, on a bank statement). Must be between 3 and 22 characters long, and not contain profanity. + # The description that appears on the receiving end for an OutboundPayment (for example, on a bank statement). Must be between 3 and 22 characters long for most destinations (500 for FinancialAccount destinations), and not contain profanity. sig { returns(T.nilable(String)) } def statement_descriptor; end sig { params(_statement_descriptor: T.nilable(String)).returns(T.nilable(String)) } @@ -278609,7 +282819,7 @@ module Stripe def recipient_verification; end sig { params(_recipient_verification: T.nilable(String)).returns(T.nilable(String)) } def recipient_verification=(_recipient_verification); end - # The description that appears on the receiving end for an OutboundTransfer (for example, on a bank statement). Must be between 3 and 22 characters long, and not contain profanity. + # The description that appears on the receiving end for an OutboundTransfer (for example, on a bank statement). Must be between 3 and 22 characters long for most destinations (500 for FinancialAccount destinations), and not contain profanity. sig { returns(T.nilable(String)) } def statement_descriptor; end sig { params(_statement_descriptor: T.nilable(String)).returns(T.nilable(String)) } @@ -280225,7 +284435,68 @@ end module Stripe module V2 module Reporting - class ReportRunRetrieveParams < ::Stripe::RequestParams; end + class ReportRunRetrieveParams < ::Stripe::RequestParams + # Any optional includes (see https://docs.stripe.com/api-includable-response-values). + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end + end + end +end +# typed: true +module Stripe + module V2 + module Signals + class AccountSignalListParams < ::Stripe::RequestParams + class AccountDetails < ::Stripe::RequestParams + # The v2 account ID of the account. + sig { returns(T.nilable(String)) } + def account; end + sig { params(_account: T.nilable(String)).returns(T.nilable(String)) } + def account=(_account); end + # The v1 customer ID of the account, for users not yet migrated to v2/accounts. + sig { returns(T.nilable(String)) } + def customer; end + sig { params(_customer: T.nilable(String)).returns(T.nilable(String)) } + def customer=(_customer); end + sig { params(account: T.nilable(String), customer: T.nilable(String)).void } + def initialize(account: nil, customer: nil); end + end + # The account or customer to list signals for. Exactly one of account_details.account or + # account_details.customer must be provided. + sig { returns(T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails)) } + def account_details; end + sig { + params(_account_details: T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails)).returns(T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails)) + } + def account_details=(_account_details); end + # Maximum number of results to return per page. Defaults to 20. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # Signal types to filter by. + sig { returns(T::Array[String]) } + def type; end + sig { params(_type: T::Array[String]).returns(T::Array[String]) } + def type=(_type); end + sig { + params(account_details: T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails), limit: T.nilable(Integer), type: T::Array[String]).void + } + def initialize(account_details: nil, limit: nil, type: nil); end + end + end + end +end +# typed: true +module Stripe + module V2 + module Signals + class AccountSignalRetrieveParams < ::Stripe::RequestParams; end end end end diff --git a/rbi/stripe/params/account_create_params.rbi b/rbi/stripe/params/account_create_params.rbi index cbea2bf97..8ffd20808 100644 --- a/rbi/stripe/params/account_create_params.rbi +++ b/rbi/stripe/params/account_create_params.rbi @@ -2643,6 +2643,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -2845,6 +2888,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji)).returns(T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji)) } def address_kanji=(_address_kanji); end + # Attribute for param field birth_address + sig { returns(T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress)).returns(T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress)) + } + def birth_address=(_birth_address); end # The individual's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountCreateParams::Individual::Dob))) } def dob; end @@ -2974,12 +3024,13 @@ module Stripe } def verification=(_verification); end sig { - params(address: T.nilable(::Stripe::AccountCreateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountCreateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountCreateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountCreateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountCreateParams::Individual::Verification)).void + params(address: T.nilable(::Stripe::AccountCreateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountCreateParams::Individual::AddressKanji), birth_address: T.nilable(::Stripe::AccountCreateParams::Individual::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountCreateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountCreateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountCreateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountCreateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountCreateParams::Individual::Verification)).void } def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, diff --git a/rbi/stripe/params/account_person_create_params.rbi b/rbi/stripe/params/account_person_create_params.rbi index 4c51fd76b..46c974141 100644 --- a/rbi/stripe/params/account_person_create_params.rbi +++ b/rbi/stripe/params/account_person_create_params.rbi @@ -181,6 +181,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -517,6 +560,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji)).returns(T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji)) } def address_kanji=(_address_kanji); end + # The person's place of birth. + sig { returns(T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress)).returns(T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress)) + } + def birth_address=(_birth_address); end # The person's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountPersonCreateParams::Dob))) } def dob; end @@ -675,13 +725,14 @@ module Stripe } def verification=(_verification); end sig { - params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonCreateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonCreateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonCreateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountPersonCreateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonCreateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonCreateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonCreateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonCreateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonCreateParams::Verification)).void + params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonCreateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonCreateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonCreateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonCreateParams::AddressKanji), birth_address: T.nilable(::Stripe::AccountPersonCreateParams::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountPersonCreateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonCreateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonCreateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonCreateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonCreateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonCreateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonCreateParams::Verification)).void } def initialize( additional_tos_acceptances: nil, address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, diff --git a/rbi/stripe/params/account_person_update_params.rbi b/rbi/stripe/params/account_person_update_params.rbi index 4627e6c1d..7cb624371 100644 --- a/rbi/stripe/params/account_person_update_params.rbi +++ b/rbi/stripe/params/account_person_update_params.rbi @@ -181,6 +181,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -517,6 +560,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji)) } def address_kanji=(_address_kanji); end + # The person's place of birth. + sig { returns(T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress)).returns(T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress)) + } + def birth_address=(_birth_address); end # The person's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountPersonUpdateParams::Dob))) } def dob; end @@ -675,13 +725,14 @@ module Stripe } def verification=(_verification); end sig { - params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonUpdateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonUpdateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountPersonUpdateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonUpdateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonUpdateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonUpdateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonUpdateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonUpdateParams::Verification)).void + params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonUpdateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonUpdateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonUpdateParams::AddressKanji), birth_address: T.nilable(::Stripe::AccountPersonUpdateParams::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountPersonUpdateParams::Dob)), documents: T.nilable(::Stripe::AccountPersonUpdateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonUpdateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonUpdateParams::Relationship), self_reported_income: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountPersonUpdateParams::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonUpdateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonUpdateParams::Verification)).void } def initialize( additional_tos_acceptances: nil, address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, diff --git a/rbi/stripe/params/account_update_params.rbi b/rbi/stripe/params/account_update_params.rbi index 3407d80ba..b0dcf6be6 100644 --- a/rbi/stripe/params/account_update_params.rbi +++ b/rbi/stripe/params/account_update_params.rbi @@ -2533,6 +2533,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -2735,6 +2778,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji)).returns(T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji)) } def address_kanji=(_address_kanji); end + # Attribute for param field birth_address + sig { returns(T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress)).returns(T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress)) + } + def birth_address=(_birth_address); end # The individual's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::AccountUpdateParams::Individual::Dob))) } def dob; end @@ -2864,12 +2914,13 @@ module Stripe } def verification=(_verification); end sig { - params(address: T.nilable(::Stripe::AccountUpdateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::AccountUpdateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountUpdateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountUpdateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountUpdateParams::Individual::Verification)).void + params(address: T.nilable(::Stripe::AccountUpdateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountUpdateParams::Individual::AddressKanji), birth_address: T.nilable(::Stripe::AccountUpdateParams::Individual::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::AccountUpdateParams::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountUpdateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountUpdateParams::Individual::Relationship), self_reported_income: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::AccountUpdateParams::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountUpdateParams::Individual::Verification)).void } def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, diff --git a/rbi/stripe/params/charge_capture_params.rbi b/rbi/stripe/params/charge_capture_params.rbi index 14a759137..ce258a526 100644 --- a/rbi/stripe/params/charge_capture_params.rbi +++ b/rbi/stripe/params/charge_capture_params.rbi @@ -2779,12 +2779,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end diff --git a/rbi/stripe/params/charge_update_params.rbi b/rbi/stripe/params/charge_update_params.rbi index fe3b0409d..6bcfd86de 100644 --- a/rbi/stripe/params/charge_update_params.rbi +++ b/rbi/stripe/params/charge_update_params.rbi @@ -2784,12 +2784,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::ChargeUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end diff --git a/rbi/stripe/params/delegated_checkout/order_retrieve_params.rbi b/rbi/stripe/params/delegated_checkout/order_retrieve_params.rbi new file mode 100644 index 000000000..7772518f0 --- /dev/null +++ b/rbi/stripe/params/delegated_checkout/order_retrieve_params.rbi @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module DelegatedCheckout + class OrderRetrieveParams < ::Stripe::RequestParams + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + sig { params(expand: T.nilable(T::Array[String])).void } + def initialize(expand: nil); end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/delegated_checkout/requested_session_list_orders_params.rbi b/rbi/stripe/params/delegated_checkout/requested_session_list_orders_params.rbi new file mode 100644 index 000000000..f642a8200 --- /dev/null +++ b/rbi/stripe/params/delegated_checkout/requested_session_list_orders_params.rbi @@ -0,0 +1,34 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module DelegatedCheckout + class RequestedSessionListOrdersParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + sig { returns(T.nilable(String)) } + def ending_before; end + sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } + def ending_before=(_ending_before); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + sig { returns(T.nilable(String)) } + def starting_after; end + sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } + def starting_after=(_starting_after); end + sig { + params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void + } + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/delegated_checkout/requested_session_order_list_params.rbi b/rbi/stripe/params/delegated_checkout/requested_session_order_list_params.rbi new file mode 100644 index 000000000..07848fd12 --- /dev/null +++ b/rbi/stripe/params/delegated_checkout/requested_session_order_list_params.rbi @@ -0,0 +1,34 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module DelegatedCheckout + class RequestedSessionOrderListParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + sig { returns(T.nilable(String)) } + def ending_before; end + sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } + def ending_before=(_ending_before); end + # Specifies which fields in the response should be expanded. + sig { returns(T.nilable(T::Array[String])) } + def expand; end + sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def expand=(_expand); end + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + sig { returns(T.nilable(String)) } + def starting_after; end + sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } + def starting_after=(_starting_after); end + sig { + params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void + } + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/payment_intent_capture_params.rbi b/rbi/stripe/params/payment_intent_capture_params.rbi index 067e7d2a8..ec4bbb7ef 100644 --- a/rbi/stripe/params/payment_intent_capture_params.rbi +++ b/rbi/stripe/params/payment_intent_capture_params.rbi @@ -3172,12 +3172,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCaptureParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end diff --git a/rbi/stripe/params/payment_intent_confirm_params.rbi b/rbi/stripe/params/payment_intent_confirm_params.rbi index d9076d817..4509652dc 100644 --- a/rbi/stripe/params/payment_intent_confirm_params.rbi +++ b/rbi/stripe/params/payment_intent_confirm_params.rbi @@ -3274,12 +3274,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -5108,6 +5110,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -5127,9 +5134,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -5608,6 +5615,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -5627,9 +5639,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentConfirmParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -5765,8 +5777,13 @@ module Stripe def networks; end sig { params(_networks: T::Array[String]).returns(T::Array[String]) } def networks=(_networks); end - sig { params(networks: T::Array[String]).void } - def initialize(networks: nil); end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end + sig { params(_static_address: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def static_address=(_static_address); end + sig { params(networks: T::Array[String], static_address: T.nilable(T::Boolean)).void } + def initialize(networks: nil, static_address: nil); end end # Specific configuration for this PaymentIntent when the mode is `deposit`. sig { diff --git a/rbi/stripe/params/payment_intent_create_params.rbi b/rbi/stripe/params/payment_intent_create_params.rbi index 9103fe27c..5832a8674 100644 --- a/rbi/stripe/params/payment_intent_create_params.rbi +++ b/rbi/stripe/params/payment_intent_create_params.rbi @@ -3284,12 +3284,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -5110,6 +5112,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -5129,9 +5136,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -5610,6 +5617,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -5629,9 +5641,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -5767,8 +5779,13 @@ module Stripe def networks; end sig { params(_networks: T::Array[String]).returns(T::Array[String]) } def networks=(_networks); end - sig { params(networks: T::Array[String]).void } - def initialize(networks: nil); end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end + sig { params(_static_address: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def static_address=(_static_address); end + sig { params(networks: T::Array[String], static_address: T.nilable(T::Boolean)).void } + def initialize(networks: nil, static_address: nil); end end # Specific configuration for this PaymentIntent when the mode is `deposit`. sig { @@ -9473,33 +9490,18 @@ module Stripe ); end end class PaymentsOrchestration < ::Stripe::RequestParams - class PaymentDetails < ::Stripe::RequestParams - # Merchant-provided reference for this payment, used for reconciliation. - sig { returns(T.nilable(String)) } - def reference; end - sig { params(_reference: T.nilable(String)).returns(T.nilable(String)) } - def reference=(_reference); end - sig { params(reference: T.nilable(String)).void } - def initialize(reference: nil); end - end # Whether this feature is enabled. sig { returns(T::Boolean) } def enabled; end sig { params(_enabled: T::Boolean).returns(T::Boolean) } def enabled=(_enabled); end - # Payment-level details for the orchestrated payment. - sig { - returns(T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)) - } - def payment_details; end - sig { - params(_payment_details: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)).returns(T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)) - } - def payment_details=(_payment_details); end - sig { - params(enabled: T::Boolean, payment_details: T.nilable(::Stripe::PaymentIntentCreateParams::PaymentsOrchestration::PaymentDetails)).void - } - def initialize(enabled: nil, payment_details: nil); end + # Merchant-provided reference for this payment, used for reconciliation. + sig { returns(T.nilable(String)) } + def payment_reference; end + sig { params(_payment_reference: T.nilable(String)).returns(T.nilable(String)) } + def payment_reference=(_payment_reference); end + sig { params(enabled: T::Boolean, payment_reference: T.nilable(String)).void } + def initialize(enabled: nil, payment_reference: nil); end end class RadarOptions < ::Stripe::RequestParams # A [Radar Session](https://docs.stripe.com/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments. diff --git a/rbi/stripe/params/payment_intent_update_params.rbi b/rbi/stripe/params/payment_intent_update_params.rbi index 852f96963..1fbe068e1 100644 --- a/rbi/stripe/params/payment_intent_update_params.rbi +++ b/rbi/stripe/params/payment_intent_update_params.rbi @@ -3253,12 +3253,14 @@ module Stripe } def account_funding=(_account_funding); end # The type of money services transaction. - sig { returns(T.nilable(String)) } + sig { returns(T.nilable(T.any(String, String))) } def transaction_type; end - sig { params(_transaction_type: T.nilable(String)).returns(T.nilable(String)) } + sig { + params(_transaction_type: T.nilable(T.any(String, String))).returns(T.nilable(T.any(String, String))) + } def transaction_type=(_transaction_type); end sig { - params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(String)).void + params(account_funding: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentDetails::MoneyServices::AccountFunding)), transaction_type: T.nilable(T.any(String, String))).void } def initialize(account_funding: nil, transaction_type: nil); end end @@ -5079,6 +5081,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -5098,9 +5105,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::Card::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -5579,6 +5586,11 @@ module Stripe } def initialize(staged_purchase: nil); end end + # The category of digital asset being acquired through this account funding transaction. + sig { returns(T.nilable(String)) } + def digital_asset_category; end + sig { params(_digital_asset_category: T.nilable(String)).returns(T.nilable(String)) } + def digital_asset_category=(_digital_asset_category); end # Details for a liquid asset (crypto or security) funding transaction. sig { returns(T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset))) @@ -5598,9 +5610,9 @@ module Stripe } def wallet=(_wallet); end sig { - params(liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void + params(digital_asset_category: T.nilable(String), liquid_asset: T.nilable(T.any(String, ::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::LiquidAsset)), wallet: T.nilable(::Stripe::PaymentIntentUpdateParams::PaymentMethodOptions::CardPresent::PaymentDetails::MoneyServices::AccountFunding::Wallet)).void } - def initialize(liquid_asset: nil, wallet: nil); end + def initialize(digital_asset_category: nil, liquid_asset: nil, wallet: nil); end end # Payment method specific account funding transaction details. sig { @@ -5736,8 +5748,13 @@ module Stripe def networks; end sig { params(_networks: T::Array[String]).returns(T::Array[String]) } def networks=(_networks); end - sig { params(networks: T::Array[String]).void } - def initialize(networks: nil); end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end + sig { params(_static_address: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } + def static_address=(_static_address); end + sig { params(networks: T::Array[String], static_address: T.nilable(T::Boolean)).void } + def initialize(networks: nil, static_address: nil); end end # Specific configuration for this PaymentIntent when the mode is `deposit`. sig { diff --git a/rbi/stripe/params/payment_location_capability_list_params.rbi b/rbi/stripe/params/payment_location_capability_list_params.rbi index d1fee119f..7e74422bc 100644 --- a/rbi/stripe/params/payment_location_capability_list_params.rbi +++ b/rbi/stripe/params/payment_location_capability_list_params.rbi @@ -9,7 +9,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # The location for which the capabilities enable functionality. + # The payment location that the capabilities enable functionality for. sig { returns(String) } def location; end sig { params(_location: String).returns(String) } diff --git a/rbi/stripe/params/payment_location_capability_retrieve_params.rbi b/rbi/stripe/params/payment_location_capability_retrieve_params.rbi index 6f7fe6c53..9da28f14b 100644 --- a/rbi/stripe/params/payment_location_capability_retrieve_params.rbi +++ b/rbi/stripe/params/payment_location_capability_retrieve_params.rbi @@ -9,7 +9,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # The payment location for which the capability enables functionality. + # The payment location that the capability enables functionality for. sig { returns(String) } def location; end sig { params(_location: String).returns(String) } diff --git a/rbi/stripe/params/payment_location_capability_update_params.rbi b/rbi/stripe/params/payment_location_capability_update_params.rbi index 2bfd8ec6c..dc6fe0dcc 100644 --- a/rbi/stripe/params/payment_location_capability_update_params.rbi +++ b/rbi/stripe/params/payment_location_capability_update_params.rbi @@ -9,7 +9,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # The location for which the capability enables functionality. + # The location that the capability enables functionality for. sig { returns(String) } def location; end sig { params(_location: String).returns(String) } diff --git a/rbi/stripe/params/payment_location_list_params.rbi b/rbi/stripe/params/payment_location_list_params.rbi index 463debeb3..6c83ef535 100644 --- a/rbi/stripe/params/payment_location_list_params.rbi +++ b/rbi/stripe/params/payment_location_list_params.rbi @@ -4,12 +4,29 @@ # typed: true module Stripe class PaymentLocationListParams < ::Stripe::RequestParams + # A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. + sig { returns(T.nilable(String)) } + def ending_before; end + sig { params(_ending_before: T.nilable(String)).returns(T.nilable(String)) } + def ending_before=(_ending_before); end # Specifies which fields in the response should be expanded. sig { returns(T.nilable(T::Array[String])) } def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - sig { params(expand: T.nilable(T::Array[String])).void } - def initialize(expand: nil); end + # A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. + sig { returns(T.nilable(String)) } + def starting_after; end + sig { params(_starting_after: T.nilable(String)).returns(T.nilable(String)) } + def starting_after=(_starting_after); end + sig { + params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void + } + def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end end end \ No newline at end of file diff --git a/rbi/stripe/params/payment_location_update_params.rbi b/rbi/stripe/params/payment_location_update_params.rbi index cb32d77c3..e1d1c7c66 100644 --- a/rbi/stripe/params/payment_location_update_params.rbi +++ b/rbi/stripe/params/payment_location_update_params.rbi @@ -80,7 +80,7 @@ module Stripe def expand; end sig { params(_expand: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } def expand=(_expand); end - # Pass true when updating location fields that will trigger onboarding review for any of the location's active location capabilities. If this parameter is not set to true, updates that would trigger onboarding review will fail. Only applicable for locations with active location capabilities. + # Pass true when updating location fields that trigger onboarding review for any of the location's active location capabilities. If this parameter isn't set to true, updates that would trigger onboarding review fail. Only applicable for locations with active location capabilities. sig { returns(T.nilable(T::Boolean)) } def onboarding_data_update_acknowledged; end sig { diff --git a/rbi/stripe/params/radar/issuing_authorization_evaluation_create_params.rbi b/rbi/stripe/params/radar/issuing_authorization_evaluation_create_params.rbi index ef8a7524b..f75e26b12 100644 --- a/rbi/stripe/params/radar/issuing_authorization_evaluation_create_params.rbi +++ b/rbi/stripe/params/radar/issuing_authorization_evaluation_create_params.rbi @@ -90,9 +90,9 @@ module Stripe sig { params(_created_at: Integer).returns(Integer) } def created_at=(_created_at); end # The last 4 digits of the card number. - sig { returns(T.nilable(String)) } + sig { returns(String) } def last4; end - sig { params(_last4: T.nilable(String)).returns(T.nilable(String)) } + sig { params(_last4: String).returns(String) } def last4=(_last4); end # User's specified unique ID of the card for this authorization attempt (e.g., RRN or internal reference). sig { returns(String) } @@ -100,7 +100,7 @@ module Stripe sig { params(_reference: String).returns(String) } def reference=(_reference); end sig { - params(bin: String, bin_country: String, card_type: String, created_at: Integer, last4: T.nilable(String), reference: String).void + params(bin: String, bin_country: String, card_type: String, created_at: Integer, last4: String, reference: String).void } def initialize( bin: nil, diff --git a/rbi/stripe/params/token_create_params.rbi b/rbi/stripe/params/token_create_params.rbi index 2932815ce..b735d4b66 100644 --- a/rbi/stripe/params/token_create_params.rbi +++ b/rbi/stripe/params/token_create_params.rbi @@ -580,6 +580,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -782,6 +825,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji)).returns(T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji)) } def address_kanji=(_address_kanji); end + # Attribute for param field birth_address + sig { returns(T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress)).returns(T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress)) + } + def birth_address=(_birth_address); end # The individual's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::TokenCreateParams::Account::Individual::Dob))) @@ -917,12 +967,13 @@ module Stripe } def verification=(_verification); end sig { - params(address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Account::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Verification)).void + params(address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Account::Individual::AddressKanji), birth_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Account::Individual::Dob)), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Account::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Account::Individual::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::TokenCreateParams::Account::Individual::Verification)).void } def initialize( address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, email: nil, first_name: nil, @@ -1319,6 +1370,49 @@ module Stripe town: nil ); end end + class BirthAddress < ::Stripe::RequestParams + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + sig { params(_city: T.nilable(String)).returns(T.nilable(String)) } + def city=(_city); end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + sig { params(_country: T.nilable(String)).returns(T.nilable(String)) } + def country=(_country); end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + sig { params(_line1: T.nilable(String)).returns(T.nilable(String)) } + def line1=(_line1); end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + sig { params(_line2: T.nilable(String)).returns(T.nilable(String)) } + def line2=(_line2); end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + sig { params(_postal_code: T.nilable(String)).returns(T.nilable(String)) } + def postal_code=(_postal_code); end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + sig { params(_state: T.nilable(String)).returns(T.nilable(String)) } + def state=(_state); end + sig { + params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void + } + def initialize( + city: nil, + country: nil, + line1: nil, + line2: nil, + postal_code: nil, + state: nil + ); end + end class Dob < ::Stripe::RequestParams # The day of birth, between 1 and 31. sig { returns(Integer) } @@ -1659,6 +1753,13 @@ module Stripe params(_address_kanji: T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji)).returns(T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji)) } def address_kanji=(_address_kanji); end + # The person's place of birth. + sig { returns(T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress)) } + def birth_address; end + sig { + params(_birth_address: T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress)).returns(T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress)) + } + def birth_address=(_birth_address); end # The person's date of birth. sig { returns(T.nilable(T.any(String, ::Stripe::TokenCreateParams::Person::Dob))) } def dob; end @@ -1807,13 +1908,14 @@ module Stripe } def verification=(_verification); end sig { - params(additional_tos_acceptances: T.nilable(::Stripe::TokenCreateParams::Person::AdditionalTosAcceptances), address: T.nilable(::Stripe::TokenCreateParams::Person::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Person::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Person::Dob)), documents: T.nilable(::Stripe::TokenCreateParams::Person::Documents), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Person::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Person::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::TokenCreateParams::Person::UsCfpbData), verification: T.nilable(::Stripe::TokenCreateParams::Person::Verification)).void + params(additional_tos_acceptances: T.nilable(::Stripe::TokenCreateParams::Person::AdditionalTosAcceptances), address: T.nilable(::Stripe::TokenCreateParams::Person::Address), address_kana: T.nilable(::Stripe::TokenCreateParams::Person::AddressKana), address_kanji: T.nilable(::Stripe::TokenCreateParams::Person::AddressKanji), birth_address: T.nilable(::Stripe::TokenCreateParams::Person::BirthAddress), dob: T.nilable(T.any(String, ::Stripe::TokenCreateParams::Person::Dob)), documents: T.nilable(::Stripe::TokenCreateParams::Person::Documents), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.any(String, T::Array[String])), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.any(String, T::Hash[String, String])), nationality: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenCreateParams::Person::RegisteredAddress), relationship: T.nilable(::Stripe::TokenCreateParams::Person::Relationship), self_reported_income: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedIncome), self_reported_monthly_housing_payment: T.nilable(::Stripe::TokenCreateParams::Person::SelfReportedMonthlyHousingPayment), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::TokenCreateParams::Person::UsCfpbData), verification: T.nilable(::Stripe::TokenCreateParams::Person::Verification)).void } def initialize( additional_tos_acceptances: nil, address: nil, address_kana: nil, address_kanji: nil, + birth_address: nil, dob: nil, documents: nil, email: nil, diff --git a/rbi/stripe/params/v2/billing/contract_activate_params.rbi b/rbi/stripe/params/v2/billing/contract_activate_params.rbi new file mode 100644 index 000000000..07b987cfa --- /dev/null +++ b/rbi/stripe/params/v2/billing/contract_activate_params.rbi @@ -0,0 +1,19 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + class ContractActivateParams < ::Stripe::RequestParams + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/billing/contract_cancel_params.rbi b/rbi/stripe/params/v2/billing/contract_cancel_params.rbi new file mode 100644 index 000000000..80bb4e4f6 --- /dev/null +++ b/rbi/stripe/params/v2/billing/contract_cancel_params.rbi @@ -0,0 +1,19 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + class ContractCancelParams < ::Stripe::RequestParams + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/billing/contract_create_params.rbi b/rbi/stripe/params/v2/billing/contract_create_params.rbi new file mode 100644 index 000000000..b61e32bde --- /dev/null +++ b/rbi/stripe/params/v2/billing/contract_create_params.rbi @@ -0,0 +1,1290 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + class ContractCreateParams < ::Stripe::RequestParams + class BillingSettings < ::Stripe::RequestParams + class ContractBillingDetails < ::Stripe::RequestParams + class BillSettingsDetails < ::Stripe::RequestParams + class Calculation < ::Stripe::RequestParams + class Tax < ::Stripe::RequestParams + # The type of tax calculation. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(type: String).void } + def initialize(type: nil); end + end + # Tax calculation settings. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)) + } + def tax; end + sig { + params(_tax: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)) + } + def tax=(_tax); end + sig { + params(tax: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation::Tax)).void + } + def initialize(tax: nil); end + end + class Invoice < ::Stripe::RequestParams + class TimeUntilDue < ::Stripe::RequestParams + # The interval unit. + sig { returns(String) } + def interval; end + sig { params(_interval: String).returns(String) } + def interval=(_interval); end + # The number of intervals. + sig { returns(Integer) } + def interval_count; end + sig { params(_interval_count: Integer).returns(Integer) } + def interval_count=(_interval_count); end + sig { params(interval: String, interval_count: Integer).void } + def initialize(interval: nil, interval_count: nil); end + end + # The number of time units before the invoice is past due. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)) + } + def time_until_due; end + sig { + params(_time_until_due: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)) + } + def time_until_due=(_time_until_due); end + sig { + params(time_until_due: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice::TimeUntilDue)).void + } + def initialize(time_until_due: nil); end + end + # Calculation settings. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation)) + } + def calculation; end + sig { + params(_calculation: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation)) + } + def calculation=(_calculation); end + # Invoice settings. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)) + } + def invoice; end + sig { + params(_invoice: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)) + } + def invoice=(_invoice); end + sig { + params(calculation: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Calculation), invoice: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails::Invoice)).void + } + def initialize(calculation: nil, invoice: nil); end + end + class BillingProfileDetails < ::Stripe::RequestParams + # The customer who pays for the contract invoice. + sig { returns(String) } + def customer; end + sig { params(_customer: String).returns(String) } + def customer=(_customer); end + # The default payment method for the contract. + sig { returns(T.nilable(String)) } + def default_payment_method; end + sig { params(_default_payment_method: T.nilable(String)).returns(T.nilable(String)) } + def default_payment_method=(_default_payment_method); end + sig { params(customer: String, default_payment_method: T.nilable(String)).void } + def initialize(customer: nil, default_payment_method: nil); end + end + class CollectionSettingsDetails < ::Stripe::RequestParams + # The collection method. + sig { returns(String) } + def collection_method; end + sig { params(_collection_method: String).returns(String) } + def collection_method=(_collection_method); end + # The payment method configuration. + sig { returns(T.nilable(String)) } + def payment_method_configuration; end + sig { + params(_payment_method_configuration: T.nilable(String)).returns(T.nilable(String)) + } + def payment_method_configuration=(_payment_method_configuration); end + sig { + params(collection_method: String, payment_method_configuration: T.nilable(String)).void + } + def initialize(collection_method: nil, payment_method_configuration: nil); end + end + # The bill settings details. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails)) + } + def bill_settings_details; end + sig { + params(_bill_settings_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails)) + } + def bill_settings_details=(_bill_settings_details); end + # The billing profile details. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails) + } + def billing_profile_details; end + sig { + params(_billing_profile_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails).returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails) + } + def billing_profile_details=(_billing_profile_details); end + # The collection settings details. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails) + } + def collection_settings_details; end + sig { + params(_collection_settings_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails).returns(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails) + } + def collection_settings_details=(_collection_settings_details); end + sig { + params(bill_settings_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillSettingsDetails), billing_profile_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::BillingProfileDetails, collection_settings_details: ::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails::CollectionSettingsDetails).void + } + def initialize( + bill_settings_details: nil, + billing_profile_details: nil, + collection_settings_details: nil + ); end + end + # Billing settings details for the contract. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)) + } + def contract_billing_details; end + sig { + params(_contract_billing_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)) + } + def contract_billing_details=(_contract_billing_details); end + sig { + params(contract_billing_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings::ContractBillingDetails)).void + } + def initialize(contract_billing_details: nil); end + end + class ContractLine < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + class Override < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + class ServiceAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class CreditGrant < ::Stripe::RequestParams + class Amount < ::Stripe::RequestParams + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + sig { + params(_monetary: T.nilable(::Stripe::V2::Amount)).returns(T.nilable(::Stripe::V2::Amount)) + } + def monetary=(_monetary); end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(monetary: T.nilable(::Stripe::V2::Amount), type: String).void } + def initialize(monetary: nil, type: nil); end + end + class ApplicabilityConfig < ::Stripe::RequestParams + class Scope < ::Stripe::RequestParams + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + sig { + params(_billable_items: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) + } + def billable_items=(_billable_items); end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + sig { params(_price_type: T.nilable(String)).returns(T.nilable(String)) } + def price_type=(_price_type); end + sig { + params(billable_items: T.nilable(T::Array[String]), price_type: T.nilable(String)).void + } + def initialize(billable_items: nil, price_type: nil); end + end + # The applicability scope of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope) + } + def scope; end + sig { + params(_scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope) + } + def scope=(_scope); end + sig { + params(scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig::Scope).void + } + def initialize(scope: nil); end + end + class ExpiryConfig < ::Stripe::RequestParams + # The type of the expiry configuration. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(type: String).void } + def initialize(type: nil); end + end + # The amount of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount) + } + def amount; end + sig { + params(_amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount) + } + def amount=(_amount); end + # Defines the scope where the credit grant is applicable. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig) + } + def applicability_config; end + sig { + params(_applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig) + } + def applicability_config=(_applicability_config); end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + sig { params(_category: T.nilable(String)).returns(T.nilable(String)) } + def category=(_category); end + # The expiry configuration for the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig) + } + def expiry_config; end + sig { + params(_expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig) + } + def expiry_config=(_expiry_config); end + # A descriptive name. + sig { returns(String) } + def name; end + sig { params(_name: String).returns(String) } + def name=(_name); end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + sig { params(_priority: T.nilable(Integer)).returns(T.nilable(Integer)) } + def priority=(_priority); end + sig { + params(amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::Amount, applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ApplicabilityConfig, category: T.nilable(String), expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant::ExpiryConfig, name: String, priority: T.nilable(Integer)).void + } + def initialize( + amount: nil, + applicability_config: nil, + category: nil, + expiry_config: nil, + name: nil, + priority: nil + ); end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant)) + } + def credit_grant; end + sig { + params(_credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant)) + } + def credit_grant=(_credit_grant); end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + sig { params(_service_interval: String).returns(String) } + def service_interval=(_service_interval); end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + sig { params(_service_interval_count: Integer).returns(Integer) } + def service_interval_count=(_service_interval_count); end + # The type of the service action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add::CreditGrant), service_interval: String, service_interval_count: Integer, type: String).void + } + def initialize( + credit_grant: nil, + service_interval: nil, + service_interval_count: nil, + type: nil + ); end + end + class Replace < ::Stripe::RequestParams + class CreditGrant < ::Stripe::RequestParams + class Amount < ::Stripe::RequestParams + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + sig { + params(_monetary: T.nilable(::Stripe::V2::Amount)).returns(T.nilable(::Stripe::V2::Amount)) + } + def monetary=(_monetary); end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(monetary: T.nilable(::Stripe::V2::Amount), type: String).void } + def initialize(monetary: nil, type: nil); end + end + class ApplicabilityConfig < ::Stripe::RequestParams + class Scope < ::Stripe::RequestParams + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + sig { + params(_billable_items: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) + } + def billable_items=(_billable_items); end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + sig { params(_price_type: T.nilable(String)).returns(T.nilable(String)) } + def price_type=(_price_type); end + sig { + params(billable_items: T.nilable(T::Array[String]), price_type: T.nilable(String)).void + } + def initialize(billable_items: nil, price_type: nil); end + end + # The applicability scope of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope) + } + def scope; end + sig { + params(_scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope) + } + def scope=(_scope); end + sig { + params(scope: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig::Scope).void + } + def initialize(scope: nil); end + end + class ExpiryConfig < ::Stripe::RequestParams + # The type of the expiry configuration. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(type: String).void } + def initialize(type: nil); end + end + # The amount of the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount) + } + def amount; end + sig { + params(_amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount) + } + def amount=(_amount); end + # Defines the scope where the credit grant is applicable. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig) + } + def applicability_config; end + sig { + params(_applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig) + } + def applicability_config=(_applicability_config); end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + sig { params(_category: T.nilable(String)).returns(T.nilable(String)) } + def category=(_category); end + # The expiry configuration for the credit grant. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig) + } + def expiry_config; end + sig { + params(_expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig) + } + def expiry_config=(_expiry_config); end + # A descriptive name. + sig { returns(String) } + def name; end + sig { params(_name: String).returns(String) } + def name=(_name); end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + sig { params(_priority: T.nilable(Integer)).returns(T.nilable(Integer)) } + def priority=(_priority); end + sig { + params(amount: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::Amount, applicability_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ApplicabilityConfig, category: T.nilable(String), expiry_config: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant::ExpiryConfig, name: String, priority: T.nilable(Integer)).void + } + def initialize( + amount: nil, + applicability_config: nil, + category: nil, + expiry_config: nil, + name: nil, + priority: nil + ); end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant)) + } + def credit_grant; end + sig { + params(_credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant)) + } + def credit_grant=(_credit_grant); end + # The ID of the service action to replace. + sig { returns(T.nilable(String)) } + def id; end + sig { params(_id: T.nilable(String)).returns(T.nilable(String)) } + def id=(_id); end + # The lookup key for the service action to replace. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + sig { params(_service_interval: String).returns(String) } + def service_interval=(_service_interval); end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + sig { params(_service_interval_count: Integer).returns(Integer) } + def service_interval_count=(_service_interval_count); end + # The type of the service action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(credit_grant: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace::CreditGrant), id: T.nilable(String), lookup_key: T.nilable(String), service_interval: String, service_interval_count: Integer, type: String).void + } + def initialize( + credit_grant: nil, + id: nil, + lookup_key: nil, + service_interval: nil, + service_interval_count: nil, + type: nil + ); end + end + # Parameters for adding a new service action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add)) + } + def add; end + sig { + params(_add: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add)) + } + def add=(_add); end + # Parameters for replacing an existing service action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace)) + } + def replace; end + sig { + params(_replace: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace)) + } + def replace=(_replace); end + # The type of service action override. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(add: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Add), replace: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction::Replace), type: String).void + } + def initialize(add: nil, replace: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + # Timestamp to indicate when the override ends. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt) + } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt) + } + def ends_at=(_ends_at); end + # Service action override parameters. Required if `type` is `service_action`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction)) + } + def service_action; end + sig { + params(_service_action: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction)) + } + def service_action=(_service_action); end + # Timestamp to indicate when the override starts. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt) + } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt) + } + def starts_at=(_starts_at); end + # The type of the override. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::EndsAt, service_action: T.nilable(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::ServiceAction), starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override::StartsAt, type: String).void + } + def initialize(ends_at: nil, service_action: nil, starts_at: nil, type: nil); end + end + class Pricing < ::Stripe::RequestParams; end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + sig { params(_timestamp: String).returns(String) } + def timestamp=(_timestamp); end + sig { params(timestamp: String).void } + def initialize(timestamp: nil); end + end + # Timestamp to indicate when the contract line ends. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt) } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt) + } + def ends_at=(_ends_at); end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # List of overrides. Later overrides in the list override earlier ones. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override]) + } + def overrides; end + sig { + params(_overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override]) + } + def overrides=(_overrides); end + # The pricing configuration for the contract line. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing) } + def pricing; end + sig { + params(_pricing: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing) + } + def pricing=(_pricing); end + # Timestamp to indicate when the contract line starts. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt) } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::EndsAt, metadata: T.nilable(T::Hash[String, String]), overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine::Override], pricing: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::Pricing, starts_at: ::Stripe::V2::Billing::ContractCreateParams::ContractLine::StartsAt).void + } + def initialize( + ends_at: nil, + metadata: nil, + overrides: nil, + pricing: nil, + starts_at: nil + ); end + end + class LicenseQuantityAction < ::Stripe::RequestParams + class EffectiveAt < ::Stripe::RequestParams + # The timestamp for the effective at. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the effective at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Set < ::Stripe::RequestParams + # The quantity to set. + sig { returns(Integer) } + def quantity; end + sig { params(_quantity: Integer).returns(Integer) } + def quantity=(_quantity); end + sig { params(quantity: Integer).void } + def initialize(quantity: nil); end + end + # The effective at for the license quantity action. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at; end + sig { + params(_effective_at: ::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt).returns(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at=(_effective_at); end + # The ID of the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_id; end + sig { params(_license_pricing_id: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_id=(_license_pricing_id); end + # The lookup key for the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_lookup_key; end + sig { params(_license_pricing_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_lookup_key=(_license_pricing_lookup_key); end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + sig { params(_license_pricing_type: String).returns(String) } + def license_pricing_type=(_license_pricing_type); end + # The pricing line for the license quantity action. + sig { returns(T.nilable(String)) } + def pricing_line; end + sig { params(_pricing_line: T.nilable(String)).returns(T.nilable(String)) } + def pricing_line=(_pricing_line); end + # The set quantity for the license quantity action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set)) + } + def set; end + sig { + params(_set: T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set)) + } + def set=(_set); end + # The type of the license quantity action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(effective_at: ::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::EffectiveAt, license_pricing_id: T.nilable(String), license_pricing_lookup_key: T.nilable(String), license_pricing_type: String, pricing_line: T.nilable(String), set: T.nilable(::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction::Set), type: String).void + } + def initialize( + effective_at: nil, + license_pricing_id: nil, + license_pricing_lookup_key: nil, + license_pricing_type: nil, + pricing_line: nil, + set: nil, + type: nil + ); end + end + class OneTimeFee < ::Stripe::RequestParams + class BillSchedule < ::Stripe::RequestParams + class BillAt < ::Stripe::RequestParams + # The datetime at which the entry should be billed. Required if `type` is `datetime`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the bill_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # When this entry should be billed. + sig { + returns(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt) + } + def bill_at; end + sig { + params(_bill_at: ::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt).returns(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt) + } + def bill_at=(_bill_at); end + # The amount to bill for this entry, in the smallest currency unit. + sig { returns(Integer) } + def value; end + sig { params(_value: Integer).returns(Integer) } + def value=(_value); end + sig { + params(bill_at: ::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule::BillAt, value: Integer).void + } + def initialize(bill_at: nil, value: nil); end + def self.field_encodings + @field_encodings = {value: :int64_string} + end + end + class ProductDetails < ::Stripe::RequestParams + # The ID of the v1 Product. + sig { returns(String) } + def product; end + sig { params(_product: String).returns(String) } + def product=(_product); end + sig { params(product: String).void } + def initialize(product: nil); end + end + # The bill schedule for the fee. Each entry produces an individual invoice item billed at `bill_at`. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule]) + } + def bill_schedule; end + sig { + params(_bill_schedule: T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule]) + } + def bill_schedule=(_bill_schedule); end + # The type of billable item that this fee references. + sig { returns(String) } + def billable_item_type; end + sig { params(_billable_item_type: String).returns(String) } + def billable_item_type=(_billable_item_type); end + # Details for a product billable target. Required when `billable_item_type` is `product`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)) + } + def product_details; end + sig { + params(_product_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)) + } + def product_details=(_product_details); end + sig { + params(bill_schedule: T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::BillSchedule], billable_item_type: String, product_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::OneTimeFee::ProductDetails)).void + } + def initialize(bill_schedule: nil, billable_item_type: nil, product_details: nil); end + def self.field_encodings + @field_encodings = { + bill_schedule: { + kind: :array, + element: {kind: :object, fields: {value: :int64_string}}, + }, + } + end + end + class PricingLine < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the ends_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Pricing < ::Stripe::RequestParams + class PriceDetails < ::Stripe::RequestParams + # The ID of the V1 price. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # The quantity for the price. Only applicable for licensed prices. + sig { returns(T.nilable(Integer)) } + def quantity; end + sig { params(_quantity: T.nilable(Integer)).returns(T.nilable(Integer)) } + def quantity=(_quantity); end + sig { params(price: String, quantity: T.nilable(Integer)).void } + def initialize(price: nil, quantity: nil); end + end + # V1 price details. Required if `type` is `price`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails)) + } + def price_details; end + sig { + params(_price_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails)) + } + def price_details=(_price_details); end + # The type of pricing. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(price_details: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing::PriceDetails), type: String).void + } + def initialize(price_details: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the starts_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # When the pricing line ends. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt) } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt) + } + def ends_at=(_ends_at); end + # A user-provided lookup key to reference this pricing line. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # The pricing configuration for the pricing line. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing) } + def pricing; end + sig { + params(_pricing: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing).returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing) + } + def pricing=(_pricing); end + # When the pricing line starts. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt) } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::EndsAt, lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), pricing: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::Pricing, starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingLine::StartsAt).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + metadata: nil, + pricing: nil, + starts_at: nil + ); end + end + class PricingOverride < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the ends_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Multiplier < ::Stripe::RequestParams + class Criterion < ::Stripe::RequestParams + class MetadataCondition < ::Stripe::RequestParams + class AllOf < ::Stripe::RequestParams + # The metadata key. + sig { returns(String) } + def key; end + sig { params(_key: String).returns(String) } + def key=(_key); end + # The metadata value. + sig { returns(String) } + def value; end + sig { params(_value: String).returns(String) } + def value=(_value); end + sig { params(key: String, value: String).void } + def initialize(key: nil, value: nil); end + end + # All of these key-value conditions must match. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of; end + sig { + params(_all_of: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of=(_all_of); end + sig { + params(all_of: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition::AllOf]).void + } + def initialize(all_of: nil); end + end + # Filter by billable item IDs. + sig { returns(T::Array[String]) } + def billable_item_ids; end + sig { params(_billable_item_ids: T::Array[String]).returns(T::Array[String]) } + def billable_item_ids=(_billable_item_ids); end + # Filter by billable item lookup keys. + sig { returns(T::Array[String]) } + def billable_item_lookup_keys; end + sig { params(_billable_item_lookup_keys: T::Array[String]).returns(T::Array[String]) } + def billable_item_lookup_keys=(_billable_item_lookup_keys); end + # Filter by billable item type. + sig { returns(T::Array[String]) } + def billable_item_types; end + sig { params(_billable_item_types: T::Array[String]).returns(T::Array[String]) } + def billable_item_types=(_billable_item_types); end + # Filter by metadata conditions. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions; end + sig { + params(_metadata_conditions: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions=(_metadata_conditions); end + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + sig { returns(T::Array[String]) } + def rate_card_ids; end + sig { params(_rate_card_ids: T::Array[String]).returns(T::Array[String]) } + def rate_card_ids=(_rate_card_ids); end + # Whether to include or exclude items matching these criteria. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(billable_item_ids: T::Array[String], billable_item_lookup_keys: T::Array[String], billable_item_types: T::Array[String], metadata_conditions: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion::MetadataCondition], rate_card_ids: T::Array[String], type: String).void + } + def initialize( + billable_item_ids: nil, + billable_item_lookup_keys: nil, + billable_item_types: nil, + metadata_conditions: nil, + rate_card_ids: nil, + type: nil + ); end + end + # Criteria determining which rates the multiplier applies to. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion]) + } + def criteria; end + sig { + params(_criteria: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion]) + } + def criteria=(_criteria); end + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + sig { returns(String) } + def factor; end + sig { params(_factor: String).returns(String) } + def factor=(_factor); end + sig { + params(criteria: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier::Criterion], factor: String).void + } + def initialize(criteria: nil, factor: nil); end + end + class OverwritePrice < ::Stripe::RequestParams + class Tier < ::Stripe::RequestParams + # Price for the entire tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def flat_amount; end + sig { params(_flat_amount: T.nilable(String)).returns(T.nilable(String)) } + def flat_amount=(_flat_amount); end + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + # Up to and including this quantity will be contained in the tier. + sig { returns(T.nilable(BigDecimal)) } + def up_to_decimal; end + sig { params(_up_to_decimal: T.nilable(BigDecimal)).returns(T.nilable(BigDecimal)) } + def up_to_decimal=(_up_to_decimal); end + # No upper bound to this tier. + sig { returns(T.nilable(String)) } + def up_to_inf; end + sig { params(_up_to_inf: T.nilable(String)).returns(T.nilable(String)) } + def up_to_inf=(_up_to_inf); end + sig { + params(flat_amount: T.nilable(String), unit_amount: T.nilable(String), up_to_decimal: T.nilable(BigDecimal), up_to_inf: T.nilable(String)).void + } + def initialize( + flat_amount: nil, + unit_amount: nil, + up_to_decimal: nil, + up_to_inf: nil + ); end + def self.field_encodings + @field_encodings = {up_to_decimal: :decimal_string} + end + end + # The ID of the V1 price to overwrite. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # Defines whether the tiered price should be graduated or volume-based. + sig { returns(T.nilable(String)) } + def tiering_mode; end + sig { params(_tiering_mode: T.nilable(String)).returns(T.nilable(String)) } + def tiering_mode=(_tiering_mode); end + # Each element represents a pricing tier. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier])) + } + def tiers; end + sig { + params(_tiers: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier])) + } + def tiers=(_tiers); end + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + sig { + params(price: String, tiering_mode: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice::Tier]), unit_amount: T.nilable(String)).void + } + def initialize(price: nil, tiering_mode: nil, tiers: nil, unit_amount: nil); end + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + } + end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. Required if `type` is `timestamp`. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the starts_at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # When the pricing override ends. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt) } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt) + } + def ends_at=(_ends_at); end + # A user-provided lookup key to reference this pricing override. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # Parameters for a multiplier override. Required if `type` is `multiplier`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier)) + } + def multiplier; end + sig { + params(_multiplier: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier)) + } + def multiplier=(_multiplier); end + # Parameters for an overwrite_price override. Required if `type` is `overwrite_price`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice)) + } + def overwrite_price; end + sig { + params(_overwrite_price: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice)) + } + def overwrite_price=(_overwrite_price); end + # The priority of this override relative to others. Lower number = higher priority. + sig { returns(Integer) } + def priority; end + sig { params(_priority: Integer).returns(Integer) } + def priority=(_priority); end + # When the pricing override starts. + sig { returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt) } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt).returns(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt) + } + def starts_at=(_starts_at); end + # The type of pricing override. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::EndsAt, lookup_key: T.nilable(String), multiplier: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::Multiplier), overwrite_price: T.nilable(::Stripe::V2::Billing::ContractCreateParams::PricingOverride::OverwritePrice), priority: Integer, starts_at: ::Stripe::V2::Billing::ContractCreateParams::PricingOverride::StartsAt, type: String).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + multiplier: nil, + overwrite_price: nil, + priority: nil, + starts_at: nil, + type: nil + ); end + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + } + end + end + # The billing settings for the contract. + sig { returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings)) } + def billing_settings; end + sig { + params(_billing_settings: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings)).returns(T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings)) + } + def billing_settings=(_billing_settings); end + # A list of contract lines to create with the contract. + sig { returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine]) } + def contract_lines; end + sig { + params(_contract_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine]) + } + def contract_lines=(_contract_lines); end + # A unique user-provided contract number e.g. C-2026-0001. + sig { returns(String) } + def contract_number; end + sig { params(_contract_number: String).returns(String) } + def contract_number=(_contract_number); end + # Currency of the contract. + sig { returns(String) } + def currency; end + sig { params(_currency: String).returns(String) } + def currency=(_currency); end + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + # A list of license quantity actions to create with the contract. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction]) + } + def license_quantity_actions; end + sig { + params(_license_quantity_actions: T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction]) + } + def license_quantity_actions=(_license_quantity_actions); end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # A list of one-time fees to create with the contract. Each fee is billed as individual invoice items per its bill_schedule. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee])) + } + def one_time_fees; end + sig { + params(_one_time_fees: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee])) + } + def one_time_fees=(_one_time_fees); end + # A list of pricing lines to create with the contract. + sig { returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine]) } + def pricing_lines; end + sig { + params(_pricing_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine]) + } + def pricing_lines=(_pricing_lines); end + # A list of pricing overrides to create with the contract. + sig { returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]) } + def pricing_overrides; end + sig { + params(_pricing_overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]).returns(T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]) + } + def pricing_overrides=(_pricing_overrides); end + sig { + params(billing_settings: T.nilable(::Stripe::V2::Billing::ContractCreateParams::BillingSettings), contract_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::ContractLine], contract_number: String, currency: String, include: T.nilable(T::Array[String]), license_quantity_actions: T::Array[::Stripe::V2::Billing::ContractCreateParams::LicenseQuantityAction], metadata: T.nilable(T::Hash[String, String]), one_time_fees: T.nilable(T::Array[::Stripe::V2::Billing::ContractCreateParams::OneTimeFee]), pricing_lines: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingLine], pricing_overrides: T::Array[::Stripe::V2::Billing::ContractCreateParams::PricingOverride]).void + } + def initialize( + billing_settings: nil, + contract_lines: nil, + contract_number: nil, + currency: nil, + include: nil, + license_quantity_actions: nil, + metadata: nil, + one_time_fees: nil, + pricing_lines: nil, + pricing_overrides: nil + ); end + def self.field_encodings + @field_encodings = { + one_time_fees: { + kind: :array, + element: { + kind: :object, + fields: { + bill_schedule: { + kind: :array, + element: {kind: :object, fields: {value: :int64_string}}, + }, + }, + }, + }, + pricing_overrides: { + kind: :array, + element: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + }, + }, + }, + } + end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/billing/contract_list_params.rbi b/rbi/stripe/params/v2/billing/contract_list_params.rbi new file mode 100644 index 000000000..1286903c1 --- /dev/null +++ b/rbi/stripe/params/v2/billing/contract_list_params.rbi @@ -0,0 +1,24 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + class ContractListParams < ::Stripe::RequestParams + # Filter by customer ID. + sig { returns(T.nilable(String)) } + def customer; end + sig { params(_customer: T.nilable(String)).returns(T.nilable(String)) } + def customer=(_customer); end + # The limit for the number of results per page. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + sig { params(customer: T.nilable(String), limit: T.nilable(Integer)).void } + def initialize(customer: nil, limit: nil); end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/billing/contract_retrieve_params.rbi b/rbi/stripe/params/v2/billing/contract_retrieve_params.rbi new file mode 100644 index 000000000..3956f8846 --- /dev/null +++ b/rbi/stripe/params/v2/billing/contract_retrieve_params.rbi @@ -0,0 +1,19 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + class ContractRetrieveParams < ::Stripe::RequestParams + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/billing/contract_update_params.rbi b/rbi/stripe/params/v2/billing/contract_update_params.rbi new file mode 100644 index 000000000..5ccc8d2ca --- /dev/null +++ b/rbi/stripe/params/v2/billing/contract_update_params.rbi @@ -0,0 +1,780 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + class ContractUpdateParams < ::Stripe::RequestParams + class LicenseQuantityAction < ::Stripe::RequestParams + class EffectiveAt < ::Stripe::RequestParams + # The timestamp for the effective at. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of the effective at. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Set < ::Stripe::RequestParams + # The quantity to set. + sig { returns(Integer) } + def quantity; end + sig { params(_quantity: Integer).returns(Integer) } + def quantity=(_quantity); end + sig { params(quantity: Integer).void } + def initialize(quantity: nil); end + end + # The effective at for the license quantity action. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at; end + sig { + params(_effective_at: ::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt).returns(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt) + } + def effective_at=(_effective_at); end + # The ID of the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_id; end + sig { params(_license_pricing_id: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_id=(_license_pricing_id); end + # The lookup key for the license pricing. + sig { returns(T.nilable(String)) } + def license_pricing_lookup_key; end + sig { params(_license_pricing_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def license_pricing_lookup_key=(_license_pricing_lookup_key); end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + sig { params(_license_pricing_type: String).returns(String) } + def license_pricing_type=(_license_pricing_type); end + # The pricing line ID for the license quantity action. + sig { returns(T.nilable(String)) } + def pricing_line; end + sig { params(_pricing_line: T.nilable(String)).returns(T.nilable(String)) } + def pricing_line=(_pricing_line); end + # The pricing line lookup key for the license quantity action. + sig { returns(T.nilable(String)) } + def pricing_line_lookup_key; end + sig { params(_pricing_line_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def pricing_line_lookup_key=(_pricing_line_lookup_key); end + # The set quantity for the license quantity action. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set)) + } + def set; end + sig { + params(_set: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set)) + } + def set=(_set); end + # The type of the license quantity action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(effective_at: ::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::EffectiveAt, license_pricing_id: T.nilable(String), license_pricing_lookup_key: T.nilable(String), license_pricing_type: String, pricing_line: T.nilable(String), pricing_line_lookup_key: T.nilable(String), set: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction::Set), type: String).void + } + def initialize( + effective_at: nil, + license_pricing_id: nil, + license_pricing_lookup_key: nil, + license_pricing_type: nil, + pricing_line: nil, + pricing_line_lookup_key: nil, + set: nil, + type: nil + ); end + end + class PricingLineAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Pricing < ::Stripe::RequestParams + class PriceDetails < ::Stripe::RequestParams + # The ID of the V1 price. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # The quantity for the price. Only applicable for licensed prices. + sig { returns(T.nilable(Integer)) } + def quantity; end + sig { params(_quantity: T.nilable(Integer)).returns(T.nilable(Integer)) } + def quantity=(_quantity); end + sig { params(price: String, quantity: T.nilable(Integer)).void } + def initialize(price: nil, quantity: nil); end + end + # V1 price details. Required if `type` is `price`. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails)) + } + def price_details; end + sig { + params(_price_details: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails)) + } + def price_details=(_price_details); end + # The type of pricing. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(price_details: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing::PriceDetails), type: String).void + } + def initialize(price_details: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The end time for the pricing line. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt) + } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt) + } + def ends_at=(_ends_at); end + # A lookup key for the pricing line. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # Metadata for the pricing line. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + sig { + params(_metadata: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) + } + def metadata=(_metadata); end + # The pricing configuration for the pricing line. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing) + } + def pricing; end + sig { + params(_pricing: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing) + } + def pricing=(_pricing); end + # The start time for the pricing line. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt) + } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::EndsAt, lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), pricing: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::Pricing, starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add::StartsAt).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + metadata: nil, + pricing: nil, + starts_at: nil + ); end + end + class Remove < ::Stripe::RequestParams + # The ID of the pricing line to remove. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + sig { params(id: String).void } + def initialize(id: nil); end + end + class Update < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The updated end time for the pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt)) + } + def ends_at; end + sig { + params(_ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt)) + } + def ends_at=(_ends_at); end + # The ID of the pricing line. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + # The updated start time for the pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)) + } + def starts_at; end + sig { + params(_starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::EndsAt), id: String, starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update::StartsAt)).void + } + def initialize(ends_at: nil, id: nil, starts_at: nil); end + end + # Parameters for adding a pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add)) + } + def add; end + sig { + params(_add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add)) + } + def add=(_add); end + # Parameters for removing a pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove)) + } + def remove; end + sig { + params(_remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove)) + } + def remove=(_remove); end + # The type of pricing line action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + # Parameters for updating a pricing line. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)) + } + def update; end + sig { + params(_update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)) + } + def update=(_update); end + sig { + params(add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Add), remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Remove), type: String, update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction::Update)).void + } + def initialize(add: nil, remove: nil, type: nil, update: nil); end + end + class PricingOverrideAction < ::Stripe::RequestParams + class Add < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class Multiplier < ::Stripe::RequestParams + class Criterion < ::Stripe::RequestParams + class MetadataCondition < ::Stripe::RequestParams + class AllOf < ::Stripe::RequestParams + # The metadata key. + sig { returns(String) } + def key; end + sig { params(_key: String).returns(String) } + def key=(_key); end + # The metadata value. + sig { returns(String) } + def value; end + sig { params(_value: String).returns(String) } + def value=(_value); end + sig { params(key: String, value: String).void } + def initialize(key: nil, value: nil); end + end + # All of these key-value conditions must match. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of; end + sig { + params(_all_of: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]) + } + def all_of=(_all_of); end + sig { + params(all_of: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition::AllOf]).void + } + def initialize(all_of: nil); end + end + # Filter by billable item IDs. + sig { returns(T::Array[String]) } + def billable_item_ids; end + sig { params(_billable_item_ids: T::Array[String]).returns(T::Array[String]) } + def billable_item_ids=(_billable_item_ids); end + # Filter by billable item lookup keys. + sig { returns(T::Array[String]) } + def billable_item_lookup_keys; end + sig { + params(_billable_item_lookup_keys: T::Array[String]).returns(T::Array[String]) + } + def billable_item_lookup_keys=(_billable_item_lookup_keys); end + # Filter by billable item type. + sig { returns(T::Array[String]) } + def billable_item_types; end + sig { params(_billable_item_types: T::Array[String]).returns(T::Array[String]) } + def billable_item_types=(_billable_item_types); end + # Filter by metadata conditions. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions; end + sig { + params(_metadata_conditions: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition]) + } + def metadata_conditions=(_metadata_conditions); end + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + sig { returns(T::Array[String]) } + def rate_card_ids; end + sig { params(_rate_card_ids: T::Array[String]).returns(T::Array[String]) } + def rate_card_ids=(_rate_card_ids); end + # Whether to include or exclude items matching these criteria. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(billable_item_ids: T::Array[String], billable_item_lookup_keys: T::Array[String], billable_item_types: T::Array[String], metadata_conditions: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion::MetadataCondition], rate_card_ids: T::Array[String], type: String).void + } + def initialize( + billable_item_ids: nil, + billable_item_lookup_keys: nil, + billable_item_types: nil, + metadata_conditions: nil, + rate_card_ids: nil, + type: nil + ); end + end + # Criteria determining which rates the multiplier applies to. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion]) + } + def criteria; end + sig { + params(_criteria: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion]) + } + def criteria=(_criteria); end + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + sig { returns(String) } + def factor; end + sig { params(_factor: String).returns(String) } + def factor=(_factor); end + sig { + params(criteria: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier::Criterion], factor: String).void + } + def initialize(criteria: nil, factor: nil); end + end + class OverwritePrice < ::Stripe::RequestParams + class Tier < ::Stripe::RequestParams + # Price for the entire tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def flat_amount; end + sig { params(_flat_amount: T.nilable(String)).returns(T.nilable(String)) } + def flat_amount=(_flat_amount); end + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + # Up to and including this quantity will be contained in the tier. + sig { returns(T.nilable(BigDecimal)) } + def up_to_decimal; end + sig { params(_up_to_decimal: T.nilable(BigDecimal)).returns(T.nilable(BigDecimal)) } + def up_to_decimal=(_up_to_decimal); end + # No upper bound to this tier. + sig { returns(T.nilable(String)) } + def up_to_inf; end + sig { params(_up_to_inf: T.nilable(String)).returns(T.nilable(String)) } + def up_to_inf=(_up_to_inf); end + sig { + params(flat_amount: T.nilable(String), unit_amount: T.nilable(String), up_to_decimal: T.nilable(BigDecimal), up_to_inf: T.nilable(String)).void + } + def initialize( + flat_amount: nil, + unit_amount: nil, + up_to_decimal: nil, + up_to_inf: nil + ); end + def self.field_encodings + @field_encodings = {up_to_decimal: :decimal_string} + end + end + # The ID of the V1 price to overwrite. + sig { returns(String) } + def price; end + sig { params(_price: String).returns(String) } + def price=(_price); end + # Defines whether the tiered price should be graduated or volume-based. + sig { returns(T.nilable(String)) } + def tiering_mode; end + sig { params(_tiering_mode: T.nilable(String)).returns(T.nilable(String)) } + def tiering_mode=(_tiering_mode); end + # Each element represents a pricing tier. + sig { + returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier]) + } + def tiers; end + sig { + params(_tiers: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier]).returns(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier]) + } + def tiers=(_tiers); end + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + sig { params(_unit_amount: T.nilable(String)).returns(T.nilable(String)) } + def unit_amount=(_unit_amount); end + sig { + params(price: String, tiering_mode: T.nilable(String), tiers: T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice::Tier], unit_amount: T.nilable(String)).void + } + def initialize(price: nil, tiering_mode: nil, tiers: nil, unit_amount: nil); end + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + } + end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The end time for the pricing override. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt) + } + def ends_at; end + sig { + params(_ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt) + } + def ends_at=(_ends_at); end + # A lookup key for the pricing override. + sig { returns(T.nilable(String)) } + def lookup_key; end + sig { params(_lookup_key: T.nilable(String)).returns(T.nilable(String)) } + def lookup_key=(_lookup_key); end + # A multiplier override to add. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier)) + } + def multiplier; end + sig { + params(_multiplier: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier)) + } + def multiplier=(_multiplier); end + # An overwrite price override to add. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice)) + } + def overwrite_price; end + sig { + params(_overwrite_price: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice)) + } + def overwrite_price=(_overwrite_price); end + # The priority for the pricing override. + sig { returns(Integer) } + def priority; end + sig { params(_priority: Integer).returns(Integer) } + def priority=(_priority); end + # The start time for the pricing override. + sig { + returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt) + } + def starts_at; end + sig { + params(_starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt).returns(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt) + } + def starts_at=(_starts_at); end + # The type of pricing override to add. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { + params(ends_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::EndsAt, lookup_key: T.nilable(String), multiplier: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::Multiplier), overwrite_price: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::OverwritePrice), priority: Integer, starts_at: ::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add::StartsAt, type: String).void + } + def initialize( + ends_at: nil, + lookup_key: nil, + multiplier: nil, + overwrite_price: nil, + priority: nil, + starts_at: nil, + type: nil + ); end + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + } + end + end + class Remove < ::Stripe::RequestParams + # The ID of the pricing override to remove. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + sig { params(id: String).void } + def initialize(id: nil); end + end + class Update < ::Stripe::RequestParams + class EndsAt < ::Stripe::RequestParams + # The timestamp when the item ends. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of end time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + class StartsAt < ::Stripe::RequestParams + # The timestamp when the item starts. + sig { returns(T.nilable(String)) } + def timestamp; end + sig { params(_timestamp: T.nilable(String)).returns(T.nilable(String)) } + def timestamp=(_timestamp); end + # The type of start time to apply. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + sig { params(timestamp: T.nilable(String), type: String).void } + def initialize(timestamp: nil, type: nil); end + end + # The updated end time for the pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt)) + } + def ends_at; end + sig { + params(_ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt)) + } + def ends_at=(_ends_at); end + # The ID of the pricing override. + sig { returns(String) } + def id; end + sig { params(_id: String).returns(String) } + def id=(_id); end + # The updated start time for the pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)) + } + def starts_at; end + sig { + params(_starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)) + } + def starts_at=(_starts_at); end + sig { + params(ends_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::EndsAt), id: String, starts_at: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update::StartsAt)).void + } + def initialize(ends_at: nil, id: nil, starts_at: nil); end + end + # Parameters for adding a pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add)) + } + def add; end + sig { + params(_add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add)) + } + def add=(_add); end + # Parameters for removing a pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove)) + } + def remove; end + sig { + params(_remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove)) + } + def remove=(_remove); end + # The type of pricing override action. + sig { returns(String) } + def type; end + sig { params(_type: String).returns(String) } + def type=(_type); end + # Parameters for updating a pricing override. + sig { + returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)) + } + def update; end + sig { + params(_update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)).returns(T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)) + } + def update=(_update); end + sig { + params(add: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Add), remove: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Remove), type: String, update: T.nilable(::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction::Update)).void + } + def initialize(add: nil, remove: nil, type: nil, update: nil); end + def self.field_encodings + @field_encodings = { + add: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + }, + }, + } + end + end + # Additional fields to include in the response. + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + # Schema-only: License quantity actions (implementation to follow). + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction])) + } + def license_quantity_actions; end + sig { + params(_license_quantity_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction])) + } + def license_quantity_actions=(_license_quantity_actions); end + # Pricing line actions to apply. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction])) + } + def pricing_line_actions; end + sig { + params(_pricing_line_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction])) + } + def pricing_line_actions=(_pricing_line_actions); end + # Pricing override actions to apply. + sig { + returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])) + } + def pricing_override_actions; end + sig { + params(_pricing_override_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])).returns(T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])) + } + def pricing_override_actions=(_pricing_override_actions); end + sig { + params(include: T.nilable(T::Array[String]), license_quantity_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::LicenseQuantityAction]), pricing_line_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingLineAction]), pricing_override_actions: T.nilable(T::Array[::Stripe::V2::Billing::ContractUpdateParams::PricingOverrideAction])).void + } + def initialize( + include: nil, + license_quantity_actions: nil, + pricing_line_actions: nil, + pricing_override_actions: nil + ); end + def self.field_encodings + @field_encodings = { + pricing_override_actions: { + kind: :array, + element: { + kind: :object, + fields: { + add: { + kind: :object, + fields: { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + }, + }, + }, + }, + }, + } + end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params.rbi b/rbi/stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params.rbi new file mode 100644 index 000000000..338e013f7 --- /dev/null +++ b/rbi/stripe/params/v2/billing/contracts/license_pricing/quantity_change_list_quantity_changes_params.rbi @@ -0,0 +1,23 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + module Contracts + module LicensePricing + class QuantityChangeListQuantityChangesParams < ::Stripe::RequestParams + # The limit for the number of results per page. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + sig { params(limit: T.nilable(Integer)).void } + def initialize(limit: nil); end + end + end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/core/account_create_params.rbi b/rbi/stripe/params/v2/core/account_create_params.rbi index 053340a84..1d6ebb7d5 100644 --- a/rbi/stripe/params/v2/core/account_create_params.rbi +++ b/rbi/stripe/params/v2/core/account_create_params.rbi @@ -2725,8 +2725,19 @@ module Stripe def losses_collector; end sig { params(_losses_collector: String).returns(String) } def losses_collector=(_losses_collector); end - sig { params(fees_collector: String, losses_collector: String).void } - def initialize(fees_collector: nil, losses_collector: nil); end + # A value indicating the party responsible for collecting requirements on this account. + sig { returns(T.nilable(String)) } + def requirements_collector; end + sig { params(_requirements_collector: T.nilable(String)).returns(T.nilable(String)) } + def requirements_collector=(_requirements_collector); end + sig { + params(fees_collector: String, losses_collector: String, requirements_collector: T.nilable(String)).void + } + def initialize( + fees_collector: nil, + losses_collector: nil, + requirements_collector: nil + ); end end # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). sig { returns(T.nilable(String)) } diff --git a/rbi/stripe/params/v2/core/account_update_params.rbi b/rbi/stripe/params/v2/core/account_update_params.rbi index 222fabe2e..ac91e7c8b 100644 --- a/rbi/stripe/params/v2/core/account_update_params.rbi +++ b/rbi/stripe/params/v2/core/account_update_params.rbi @@ -2775,8 +2775,19 @@ module Stripe def losses_collector; end sig { params(_losses_collector: String).returns(String) } def losses_collector=(_losses_collector); end - sig { params(fees_collector: String, losses_collector: String).void } - def initialize(fees_collector: nil, losses_collector: nil); end + # A value indicating the party responsible for collecting requirements on this account. + sig { returns(T.nilable(String)) } + def requirements_collector; end + sig { params(_requirements_collector: T.nilable(String)).returns(T.nilable(String)) } + def requirements_collector=(_requirements_collector); end + sig { + params(fees_collector: String, losses_collector: String, requirements_collector: T.nilable(String)).void + } + def initialize( + fees_collector: nil, + losses_collector: nil, + requirements_collector: nil + ); end end # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). sig { returns(T.nilable(String)) } diff --git a/rbi/stripe/params/v2/data/reporting/query_run_retrieve_params.rbi b/rbi/stripe/params/v2/data/reporting/query_run_retrieve_params.rbi index 22e8bc2aa..d0fbb60cc 100644 --- a/rbi/stripe/params/v2/data/reporting/query_run_retrieve_params.rbi +++ b/rbi/stripe/params/v2/data/reporting/query_run_retrieve_params.rbi @@ -6,7 +6,15 @@ module Stripe module V2 module Data module Reporting - class QueryRunRetrieveParams < ::Stripe::RequestParams; end + class QueryRunRetrieveParams < ::Stripe::RequestParams + # Any optional includes (see https://docs.stripe.com/api-includable-response-values). + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end end end end diff --git a/rbi/stripe/params/v2/money_management/outbound_payment_create_params.rbi b/rbi/stripe/params/v2/money_management/outbound_payment_create_params.rbi index 00ddabf02..bc2ba7869 100644 --- a/rbi/stripe/params/v2/money_management/outbound_payment_create_params.rbi +++ b/rbi/stripe/params/v2/money_management/outbound_payment_create_params.rbi @@ -160,7 +160,7 @@ module Stripe def recipient_verification; end sig { params(_recipient_verification: T.nilable(String)).returns(T.nilable(String)) } def recipient_verification=(_recipient_verification); end - # The description that appears on the receiving end for an OutboundPayment (for example, on a bank statement). Must be between 3 and 22 characters long, and not contain profanity. + # The description that appears on the receiving end for an OutboundPayment (for example, on a bank statement). Must be between 3 and 22 characters long for most destinations (500 for FinancialAccount destinations), and not contain profanity. sig { returns(T.nilable(String)) } def statement_descriptor; end sig { params(_statement_descriptor: T.nilable(String)).returns(T.nilable(String)) } diff --git a/rbi/stripe/params/v2/money_management/outbound_transfer_create_params.rbi b/rbi/stripe/params/v2/money_management/outbound_transfer_create_params.rbi index 70ff27f29..9c5df325e 100644 --- a/rbi/stripe/params/v2/money_management/outbound_transfer_create_params.rbi +++ b/rbi/stripe/params/v2/money_management/outbound_transfer_create_params.rbi @@ -87,7 +87,7 @@ module Stripe def recipient_verification; end sig { params(_recipient_verification: T.nilable(String)).returns(T.nilable(String)) } def recipient_verification=(_recipient_verification); end - # The description that appears on the receiving end for an OutboundTransfer (for example, on a bank statement). Must be between 3 and 22 characters long, and not contain profanity. + # The description that appears on the receiving end for an OutboundTransfer (for example, on a bank statement). Must be between 3 and 22 characters long for most destinations (500 for FinancialAccount destinations), and not contain profanity. sig { returns(T.nilable(String)) } def statement_descriptor; end sig { params(_statement_descriptor: T.nilable(String)).returns(T.nilable(String)) } diff --git a/rbi/stripe/params/v2/reporting/report_run_retrieve_params.rbi b/rbi/stripe/params/v2/reporting/report_run_retrieve_params.rbi index 44cea14ff..ff080cbd6 100644 --- a/rbi/stripe/params/v2/reporting/report_run_retrieve_params.rbi +++ b/rbi/stripe/params/v2/reporting/report_run_retrieve_params.rbi @@ -5,7 +5,15 @@ module Stripe module V2 module Reporting - class ReportRunRetrieveParams < ::Stripe::RequestParams; end + class ReportRunRetrieveParams < ::Stripe::RequestParams + # Any optional includes (see https://docs.stripe.com/api-includable-response-values). + sig { returns(T.nilable(T::Array[String])) } + def include; end + sig { params(_include: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def include=(_include); end + sig { params(include: T.nilable(T::Array[String])).void } + def initialize(include: nil); end + end end end end \ No newline at end of file diff --git a/rbi/stripe/params/v2/signals/account_signal_list_params.rbi b/rbi/stripe/params/v2/signals/account_signal_list_params.rbi new file mode 100644 index 000000000..4c89cb6a5 --- /dev/null +++ b/rbi/stripe/params/v2/signals/account_signal_list_params.rbi @@ -0,0 +1,48 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Signals + class AccountSignalListParams < ::Stripe::RequestParams + class AccountDetails < ::Stripe::RequestParams + # The v2 account ID of the account. + sig { returns(T.nilable(String)) } + def account; end + sig { params(_account: T.nilable(String)).returns(T.nilable(String)) } + def account=(_account); end + # The v1 customer ID of the account, for users not yet migrated to v2/accounts. + sig { returns(T.nilable(String)) } + def customer; end + sig { params(_customer: T.nilable(String)).returns(T.nilable(String)) } + def customer=(_customer); end + sig { params(account: T.nilable(String), customer: T.nilable(String)).void } + def initialize(account: nil, customer: nil); end + end + # The account or customer to list signals for. Exactly one of account_details.account or + # account_details.customer must be provided. + sig { returns(T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails)) } + def account_details; end + sig { + params(_account_details: T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails)).returns(T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails)) + } + def account_details=(_account_details); end + # Maximum number of results to return per page. Defaults to 20. + sig { returns(T.nilable(Integer)) } + def limit; end + sig { params(_limit: T.nilable(Integer)).returns(T.nilable(Integer)) } + def limit=(_limit); end + # Signal types to filter by. + sig { returns(T::Array[String]) } + def type; end + sig { params(_type: T::Array[String]).returns(T::Array[String]) } + def type=(_type); end + sig { + params(account_details: T.nilable(::Stripe::V2::Signals::AccountSignalListParams::AccountDetails), limit: T.nilable(Integer), type: T::Array[String]).void + } + def initialize(account_details: nil, limit: nil, type: nil); end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/params/v2/signals/account_signal_retrieve_params.rbi b/rbi/stripe/params/v2/signals/account_signal_retrieve_params.rbi new file mode 100644 index 000000000..2f2104442 --- /dev/null +++ b/rbi/stripe/params/v2/signals/account_signal_retrieve_params.rbi @@ -0,0 +1,11 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Signals + class AccountSignalRetrieveParams < ::Stripe::RequestParams; end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/resources/delegated_checkout/order.rbi b/rbi/stripe/resources/delegated_checkout/order.rbi new file mode 100644 index 000000000..8d41787ec --- /dev/null +++ b/rbi/stripe/resources/delegated_checkout/order.rbi @@ -0,0 +1,150 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module DelegatedCheckout + # An order represents the post-checkout lifecycle of a delegated checkout purchase. + class Order < APIResource + class LineItem < ::Stripe::StripeObject + class ProductDetails < ::Stripe::StripeObject + # The item description. + sig { returns(T.nilable(String)) } + def description; end + # The item images. + sig { returns(T.nilable(T::Array[String])) } + def images; end + # The item title. + sig { returns(String) } + def title; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Quantity < ::Stripe::StripeObject + # The current quantity. + sig { returns(Integer) } + def current; end + # The ordered quantity. + sig { returns(Integer) } + def ordered; end + # The shipped quantity. + sig { returns(Integer) } + def shipped; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Totals < ::Stripe::StripeObject + # The base amount for the line item. + sig { returns(T.nilable(Integer)) } + def base_amount; end + # The discount amount for the line item. + sig { returns(T.nilable(Integer)) } + def discount; end + # The subtotal amount for the line item. + sig { returns(T.nilable(Integer)) } + def subtotal; end + # The tax amount for the line item. + sig { returns(T.nilable(Integer)) } + def tax; end + # The total amount for the line item. + sig { returns(T.nilable(Integer)) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The order line item key. + sig { returns(String) } + def key; end + # Attribute for field product_details + sig { returns(ProductDetails) } + def product_details; end + # Attribute for field quantity + sig { returns(Quantity) } + def quantity; end + # The SKU ID of the line item. + sig { returns(String) } + def sku_id; end + # The totals for this line item. + sig { returns(T.nilable(Totals)) } + def totals; end + # The line item unit amount. + sig { returns(Integer) } + def unit_amount; end + def self.inner_class_types + @inner_class_types = {product_details: ProductDetails, quantity: Quantity, totals: Totals} + end + def self.field_remappings + @field_remappings = {} + end + end + class Totals < ::Stripe::StripeObject + # The discount amount for the order. + sig { returns(T.nilable(Integer)) } + def discount; end + # The fulfillment amount for the order. + sig { returns(T.nilable(Integer)) } + def fulfillment; end + # The subtotal amount for the order. + sig { returns(T.nilable(Integer)) } + def subtotal; end + # The tax amount for the order. + sig { returns(T.nilable(Integer)) } + def tax; end + # The total amount for the order. + sig { returns(T.nilable(Integer)) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Time at which the object was created. Measured in seconds since the Unix epoch. + sig { returns(Integer) } + def created; end + # Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies). + sig { returns(String) } + def currency; end + # Unique identifier for the object. + sig { returns(String) } + def id; end + # The latest order event for this order. + sig { returns(T.nilable(::Stripe::DelegatedCheckout::OrderEvent)) } + def latest_order_event; end + # The line items in this order. + sig { returns(T::Array[LineItem]) } + def line_items; end + # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. + sig { returns(T::Boolean) } + def livemode; end + # String representing the object's type. Objects of the same type share the same value. + sig { returns(String) } + def object; end + # The permalink URL for this order. + sig { returns(T.nilable(String)) } + def permalink_url; end + # The requested session associated with this order. + sig { returns(String) } + def requested_session; end + # The seller reference for this order. + sig { returns(T.nilable(String)) } + def seller_reference; end + # The totals for this order. + sig { returns(T.nilable(Totals)) } + def totals; end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/resources/delegated_checkout/order_event.rbi b/rbi/stripe/resources/delegated_checkout/order_event.rbi new file mode 100644 index 000000000..17444da64 --- /dev/null +++ b/rbi/stripe/resources/delegated_checkout/order_event.rbi @@ -0,0 +1,124 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module DelegatedCheckout + # An order event represents a change to a delegated checkout order. + class OrderEvent < APIResource + class Adjustment < ::Stripe::StripeObject + class LineItem < ::Stripe::StripeObject + # The line item key. + sig { returns(String) } + def key; end + # The quantity associated with the order event. + sig { returns(Integer) } + def quantity; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The amount associated with the adjustment. + sig { returns(T.nilable(Integer)) } + def amount; end + # The currency associated with the adjustment amount. + sig { returns(T.nilable(String)) } + def currency; end + # The description of the adjustment. + sig { returns(String) } + def description; end + # The line items associated with the adjustment. + sig { returns(T.nilable(T::Array[LineItem])) } + def line_items; end + # The status of the adjustment. + sig { returns(String) } + def status; end + # The type of adjustment. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {line_items: LineItem} + end + def self.field_remappings + @field_remappings = {} + end + end + class Fulfillment < ::Stripe::StripeObject + class LineItem < ::Stripe::StripeObject + # The line item key. + sig { returns(String) } + def key; end + # The quantity associated with the order event. + sig { returns(Integer) } + def quantity; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The carrier for the fulfillment. + sig { returns(T.nilable(String)) } + def carrier; end + # Time at which the fulfillment was delivered. Measured in seconds since the Unix epoch. + sig { returns(T.nilable(Integer)) } + def delivered_at; end + # The line items associated with the fulfillment. + sig { returns(T::Array[LineItem]) } + def line_items; end + # Time at which the fulfillment shipped. Measured in seconds since the Unix epoch. + sig { returns(T.nilable(Integer)) } + def shipped_at; end + # The status of the fulfillment. + sig { returns(String) } + def status; end + # The tracking number for the fulfillment. + sig { returns(T.nilable(String)) } + def tracking_number; end + # The tracking URL for the fulfillment. + sig { returns(T.nilable(String)) } + def tracking_url; end + def self.inner_class_types + @inner_class_types = {line_items: LineItem} + end + def self.field_remappings + @field_remappings = {} + end + end + # The adjustment details for this order event. + sig { returns(T.nilable(Adjustment)) } + def adjustment; end + # Time at which the object was created. Measured in seconds since the Unix epoch. + sig { returns(Integer) } + def created; end + # The fulfillment details for this order event. + sig { returns(T.nilable(Fulfillment)) } + def fulfillment; end + # Unique identifier for the object. + sig { returns(String) } + def id; end + # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. + sig { returns(T::Boolean) } + def livemode; end + # String representing the object's type. Objects of the same type share the same value. + sig { returns(String) } + def object; end + # Time at which this event occurred. Measured in seconds since the Unix epoch. + sig { returns(Integer) } + def occurred_at; end + # The delegated checkout order associated with this order event. + sig { returns(String) } + def order; end + # The requested session associated with this order event. + sig { returns(String) } + def requested_session; end + # The type of order event. + sig { returns(String) } + def type; end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/resources/delegated_checkout/requested_session.rbi b/rbi/stripe/resources/delegated_checkout/requested_session.rbi index b89fdc1f3..4184a5b98 100644 --- a/rbi/stripe/resources/delegated_checkout/requested_session.rbi +++ b/rbi/stripe/resources/delegated_checkout/requested_session.rbi @@ -882,6 +882,18 @@ module Stripe } def self.expire(requested_session, params = {}, opts = {}); end + # Lists orders for a delegated checkout requested session. + sig { + params(params: T.any(::Stripe::DelegatedCheckout::RequestedSessionListOrdersParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) + } + def list_orders(params = {}, opts = {}); end + + # Lists orders for a delegated checkout requested session. + sig { + params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionListOrdersParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) + } + def self.list_orders(requested_session, params = {}, opts = {}); end + # Updates a requested session sig { params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::DelegatedCheckout::RequestedSession) diff --git a/rbi/stripe/resources/issuing/authorization.rbi b/rbi/stripe/resources/issuing/authorization.rbi index 8fdcb144b..8f05266c4 100644 --- a/rbi/stripe/resources/issuing/authorization.rbi +++ b/rbi/stripe/resources/issuing/authorization.rbi @@ -567,6 +567,9 @@ module Stripe # A unique reference ID from the network to represent the card account number. sig { returns(T.nilable(String)) } def card_reference_id; end + # Stripe's recommendation to the network for this token activation request, derived from the same risk signals used for the activation decision. + sig { returns(T.nilable(String)) } + def token_decision_recommendation; end # The network-unique identifier for the token. sig { returns(String) } def token_reference_id; end @@ -645,6 +648,12 @@ module Stripe # Attribute for field network_data sig { returns(T.nilable(NetworkData)) } def network_data; end + # The decision made during token provisioning. + sig { returns(T.nilable(String)) } + def provisioning_decision; end + # The type of the token, indicating how it is used. + sig { returns(T.nilable(String)) } + def token_type; end def self.inner_class_types @inner_class_types = {network_data: NetworkData} end diff --git a/rbi/stripe/resources/issuing/token.rbi b/rbi/stripe/resources/issuing/token.rbi index ee5911c99..8e207b1e8 100644 --- a/rbi/stripe/resources/issuing/token.rbi +++ b/rbi/stripe/resources/issuing/token.rbi @@ -14,6 +14,9 @@ module Stripe # The IP address of the device at provisioning time. sig { returns(T.nilable(String)) } def ip_address; end + # The ISO 639-1 language code of the device associated with the tokenization request. + sig { returns(T.nilable(String)) } + def language; end # The geographic latitude/longitude coordinates of the device at provisioning time. The format is [+-]decimal/[+-]decimal. sig { returns(T.nilable(String)) } def location; end @@ -57,6 +60,9 @@ module Stripe # A unique reference ID from Visa to represent the card account number. sig { returns(T.nilable(String)) } def card_reference_id; end + # Stripe's recommendation to the network for this token activation request, derived from the same risk signals used for the activation decision. + sig { returns(T.nilable(String)) } + def token_decision_recommendation; end # The network-unique identifier for the token. sig { returns(String) } def token_reference_id; end @@ -182,9 +188,15 @@ module Stripe # String representing the object's type. Objects of the same type share the same value. sig { returns(String) } def object; end + # The decision made during token provisioning. + sig { returns(T.nilable(String)) } + def provisioning_decision; end # The usage state of the token. sig { returns(String) } def status; end + # The type of the token, indicating how it is used. + sig { returns(T.nilable(String)) } + def token_type; end # The digital wallet for this token, if one was used. sig { returns(T.nilable(String)) } def wallet_provider; end diff --git a/rbi/stripe/resources/payment_intent.rbi b/rbi/stripe/resources/payment_intent.rbi index 28e518e3b..ec8bf53a6 100644 --- a/rbi/stripe/resources/payment_intent.rbi +++ b/rbi/stripe/resources/payment_intent.rbi @@ -3815,6 +3815,9 @@ module Stripe # The blockchain networks to support for deposits. Learn more about [supported networks and tokens](https://docs.stripe.com/payments/deposit-mode-stablecoin-payments#token-and-network-support). sig { returns(T.nilable(T::Array[String])) } def networks; end + # If true, provisions a permanent per-customer deposit address reused across PaymentIntents. + sig { returns(T.nilable(T::Boolean)) } + def static_address; end def self.inner_class_types @inner_class_types = {} end diff --git a/rbi/stripe/resources/payment_location.rbi b/rbi/stripe/resources/payment_location.rbi index 5aad25300..59d9fcfb2 100644 --- a/rbi/stripe/resources/payment_location.rbi +++ b/rbi/stripe/resources/payment_location.rbi @@ -84,7 +84,7 @@ module Stripe # Identification numbers associated with the location. sig { returns(T.nilable(BusinessRegistration)) } def business_registration; end - # The capability settings for the location. Only applicable for locations with requested Payment Location Capabilities. + # The capability settings for the location. Only applicable for locations with requested payment location capabilities. sig { returns(T.nilable(CapabilitySettings)) } def capability_settings; end # Always true for a deleted object diff --git a/rbi/stripe/resources/payment_location_capability.rbi b/rbi/stripe/resources/payment_location_capability.rbi index aa8a385cc..83eddc686 100644 --- a/rbi/stripe/resources/payment_location_capability.rbi +++ b/rbi/stripe/resources/payment_location_capability.rbi @@ -3,7 +3,7 @@ # typed: true module Stripe - # A Payment Location Capability represents a capability for a Stripe account at a Payment Location. + # A `payment_location` capability represents a capability for a Stripe account at a payment location. class PaymentLocationCapability < APIResource class Requirements < ::Stripe::StripeObject class Error < ::Stripe::StripeObject @@ -39,7 +39,7 @@ module Stripe @field_remappings = {} end end - # The account for which the capability enables functionality. + # The account that the capability enables functionality for. sig { returns(String) } def account; end # The identifier for the capability. @@ -48,7 +48,7 @@ module Stripe # If the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`. sig { returns(T::Boolean) } def livemode; end - # The payment location for which the capability enables functionality. + # The payment location that the capability enables functionality for. sig { returns(String) } def location; end # String representing the object's type. Objects of the same type share the same value. @@ -57,7 +57,7 @@ module Stripe # Whether the capability has been requested. sig { returns(T::Boolean) } def requested; end - # Time at which the capability was requested. Measured in seconds since the Unix epoch. + # Time when the capability was requested. Measured in seconds since the Unix epoch. sig { returns(T.nilable(Integer)) } def requested_at; end # Attribute for field requirements @@ -66,13 +66,13 @@ module Stripe # The status of the capability. sig { returns(String) } def status; end - # Returns a list of PaymentLocationCapability objects associated with the location. + # List all payment location capabilities associated with the payment location. sig { params(params: T.any(::Stripe::PaymentLocationCapabilityListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) } def self.list(params = {}, opts = {}); end - # Updates a specified Payment Location Capability. Request or remove a payment location capability by updating its requested parameter. + # Updates a payment_location capability. Request or remove a payment_location capability by updating its requested parameter. sig { params(capability: String, params: T.any(::Stripe::PaymentLocationCapabilityUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::PaymentLocationCapability) } diff --git a/rbi/stripe/resources/person.rbi b/rbi/stripe/resources/person.rbi index 6fbb6988a..ff2c93314 100644 --- a/rbi/stripe/resources/person.rbi +++ b/rbi/stripe/resources/person.rbi @@ -121,6 +121,32 @@ module Stripe @field_remappings = {} end end + class BirthAddress < ::Stripe::StripeObject + # City, district, suburb, town, or village. + sig { returns(T.nilable(String)) } + def city; end + # Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)). + sig { returns(T.nilable(String)) } + def country; end + # Address line 1, such as the street, PO Box, or company name. + sig { returns(T.nilable(String)) } + def line1; end + # Address line 2, such as the apartment, suite, unit, or building. + sig { returns(T.nilable(String)) } + def line2; end + # ZIP or postal code. + sig { returns(T.nilable(String)) } + def postal_code; end + # State, county, province, or region ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)). + sig { returns(T.nilable(String)) } + def state; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end class Dob < ::Stripe::StripeObject # The day of birth, between 1 and 31. sig { returns(T.nilable(Integer)) } @@ -461,6 +487,9 @@ module Stripe # The Kanji variation of the person's address (Japan only). sig { returns(T.nilable(AddressKanji)) } def address_kanji; end + # Attribute for field birth_address + sig { returns(T.nilable(BirthAddress)) } + def birth_address; end # Time at which the object was created. Measured in seconds since the Unix epoch. sig { returns(Integer) } def created; end diff --git a/rbi/stripe/resources/v2/billing/contract.rbi b/rbi/stripe/resources/v2/billing/contract.rbi new file mode 100644 index 000000000..85220a053 --- /dev/null +++ b/rbi/stripe/resources/v2/billing/contract.rbi @@ -0,0 +1,928 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + # Main Contract resource representing a comprehensive billing agreement + class Contract < APIResource + class BillingSettings < ::Stripe::StripeObject + class ContractBillingDetails < ::Stripe::StripeObject + class BillSettingsDetails < ::Stripe::StripeObject + class Calculation < ::Stripe::StripeObject + class Tax < ::Stripe::StripeObject + # The type of tax calculation. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Tax calculation settings. + sig { returns(T.nilable(Tax)) } + def tax; end + def self.inner_class_types + @inner_class_types = {tax: Tax} + end + def self.field_remappings + @field_remappings = {} + end + end + class Invoice < ::Stripe::StripeObject + class TimeUntilDue < ::Stripe::StripeObject + # The interval unit. + sig { returns(String) } + def interval; end + # The number of intervals. + sig { returns(Integer) } + def interval_count; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The number of time units before the invoice is past due. + sig { returns(T.nilable(TimeUntilDue)) } + def time_until_due; end + def self.inner_class_types + @inner_class_types = {time_until_due: TimeUntilDue} + end + def self.field_remappings + @field_remappings = {} + end + end + # Calculation settings. + sig { returns(T.nilable(Calculation)) } + def calculation; end + # Invoice settings. + sig { returns(T.nilable(Invoice)) } + def invoice; end + def self.inner_class_types + @inner_class_types = {calculation: Calculation, invoice: Invoice} + end + def self.field_remappings + @field_remappings = {} + end + end + class BillingProfileDetails < ::Stripe::StripeObject + # The customer who pays for the contract invoice. + sig { returns(String) } + def customer; end + # The default payment method for the contract. + sig { returns(T.nilable(String)) } + def default_payment_method; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class CollectionSettingsDetails < ::Stripe::StripeObject + # The collection method. + sig { returns(String) } + def collection_method; end + # The payment method configuration. + sig { returns(T.nilable(String)) } + def payment_method_configuration; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The bill settings details. + sig { returns(T.nilable(BillSettingsDetails)) } + def bill_settings_details; end + # The billing profile details. + sig { returns(BillingProfileDetails) } + def billing_profile_details; end + # The collection settings details. + sig { returns(CollectionSettingsDetails) } + def collection_settings_details; end + def self.inner_class_types + @inner_class_types = { + bill_settings_details: BillSettingsDetails, + billing_profile_details: BillingProfileDetails, + collection_settings_details: CollectionSettingsDetails, + } + end + def self.field_remappings + @field_remappings = {} + end + end + # Billing settings details for the contract. + sig { returns(T.nilable(ContractBillingDetails)) } + def contract_billing_details; end + def self.inner_class_types + @inner_class_types = {contract_billing_details: ContractBillingDetails} + end + def self.field_remappings + @field_remappings = {} + end + end + class ContractLineDetail < ::Stripe::StripeObject + class ContractLineValueDetails < ::Stripe::StripeObject + # Computed sum of all licensed fees. Represented as a decimal string in minor currency units. + sig { returns(String) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Override < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class ServiceAction < ::Stripe::StripeObject + class Add < ::Stripe::StripeObject + class CreditGrant < ::Stripe::StripeObject + class Amount < ::Stripe::StripeObject + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class ApplicabilityConfig < ::Stripe::StripeObject + class Scope < ::Stripe::StripeObject + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The applicability scope of the credit grant. + sig { returns(Scope) } + def scope; end + def self.inner_class_types + @inner_class_types = {scope: Scope} + end + def self.field_remappings + @field_remappings = {} + end + end + class ExpiryConfig < ::Stripe::StripeObject + # The type of the expiry configuration. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The amount of the credit grant. + sig { returns(Amount) } + def amount; end + # Defines the scope where the credit grant is applicable. + sig { returns(ApplicabilityConfig) } + def applicability_config; end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + # The expiry configuration for the credit grant. + sig { returns(ExpiryConfig) } + def expiry_config; end + # A descriptive name. + sig { returns(String) } + def name; end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + def self.inner_class_types + @inner_class_types = { + amount: Amount, + applicability_config: ApplicabilityConfig, + expiry_config: ExpiryConfig, + } + end + def self.field_remappings + @field_remappings = {} + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { returns(T.nilable(CreditGrant)) } + def credit_grant; end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + # The type of the service action. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {credit_grant: CreditGrant} + end + def self.field_remappings + @field_remappings = {} + end + end + class Replace < ::Stripe::StripeObject + class CreditGrant < ::Stripe::StripeObject + class Amount < ::Stripe::StripeObject + # The monetary amount of the credit grant. Required if `type` is `monetary`. + sig { returns(T.nilable(::Stripe::V2::Amount)) } + def monetary; end + # The type of the credit grant amount. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class ApplicabilityConfig < ::Stripe::StripeObject + class Scope < ::Stripe::StripeObject + # The billable items to apply the credit grant to. + sig { returns(T.nilable(T::Array[String])) } + def billable_items; end + # The price type that credit grants can apply to. + sig { returns(T.nilable(String)) } + def price_type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The applicability scope of the credit grant. + sig { returns(Scope) } + def scope; end + def self.inner_class_types + @inner_class_types = {scope: Scope} + end + def self.field_remappings + @field_remappings = {} + end + end + class ExpiryConfig < ::Stripe::StripeObject + # The type of the expiry configuration. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The amount of the credit grant. + sig { returns(Amount) } + def amount; end + # Defines the scope where the credit grant is applicable. + sig { returns(ApplicabilityConfig) } + def applicability_config; end + # The category of the credit grant. + sig { returns(T.nilable(String)) } + def category; end + # The expiry configuration for the credit grant. + sig { returns(ExpiryConfig) } + def expiry_config; end + # A descriptive name. + sig { returns(String) } + def name; end + # The desired priority for applying this credit grant. The highest priority is 0 and the lowest is 100. + sig { returns(T.nilable(Integer)) } + def priority; end + def self.inner_class_types + @inner_class_types = { + amount: Amount, + applicability_config: ApplicabilityConfig, + expiry_config: ExpiryConfig, + } + end + def self.field_remappings + @field_remappings = {} + end + end + # Details for the credit grant. Required if `type` is `credit_grant`. + sig { returns(T.nilable(CreditGrant)) } + def credit_grant; end + # The ID of the service action to replace. + sig { returns(T.nilable(String)) } + def id; end + # The lookup key for the service action to replace. + sig { returns(T.nilable(String)) } + def lookup_key; end + # The interval for assessing service. + sig { returns(String) } + def service_interval; end + # The length of the interval for assessing service. + sig { returns(Integer) } + def service_interval_count; end + # The type of the service action. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {credit_grant: CreditGrant} + end + def self.field_remappings + @field_remappings = {} + end + end + # Parameters for adding a new service action. + sig { returns(T.nilable(Add)) } + def add; end + # Parameters for replacing an existing service action. + sig { returns(T.nilable(Replace)) } + def replace; end + # The type of service action override. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {add: Add, replace: Replace} + end + def self.field_remappings + @field_remappings = {} + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Timestamp to indicate when the override ends. + sig { returns(EndsAt) } + def ends_at; end + # Service action override details. + sig { returns(T.nilable(ServiceAction)) } + def service_action; end + # Timestamp to indicate when the override starts. + sig { returns(StartsAt) } + def starts_at; end + # The type of the override. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = { + ends_at: EndsAt, + service_action: ServiceAction, + starts_at: StartsAt, + } + end + def self.field_remappings + @field_remappings = {} + end + end + class Pricing < ::Stripe::StripeObject + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The ID of the contract line. + sig { returns(String) } + def contract_line; end + # The computed value details for the contract line. + sig { returns(ContractLineValueDetails) } + def contract_line_value_details; end + # Timestamp of when the object was created. + sig { returns(String) } + def created; end + # Timestamp to indicate when the contract line ends. + sig { returns(EndsAt) } + def ends_at; end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + # List of overrides applied to the contract line. + sig { returns(T::Array[Override]) } + def overrides; end + # The pricing configuration for the contract line. + sig { returns(Pricing) } + def pricing; end + # Timestamp to indicate when the contract line starts. + sig { returns(StartsAt) } + def starts_at; end + def self.inner_class_types + @inner_class_types = { + contract_line_value_details: ContractLineValueDetails, + ends_at: EndsAt, + overrides: Override, + pricing: Pricing, + starts_at: StartsAt, + } + end + def self.field_remappings + @field_remappings = {} + end + end + class ContractValueDetails < ::Stripe::StripeObject + # The total value represented as a decimal string in minor currency units. + sig { returns(String) } + def total; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class LicenseQuantity < ::Stripe::StripeObject + # The ID of the license pricing. + sig { returns(String) } + def license_pricing_id; end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + # The ID of the pricing line associated with this license quantity. + sig { returns(String) } + def pricing_line; end + # The current quantity of the license. + sig { returns(Integer) } + def quantity; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class OneTimeFee < ::Stripe::StripeObject + class BillSchedule < ::Stripe::StripeObject + class BillAt < ::Stripe::StripeObject + # The datetime at which the entry will be billed. Set when `type` is `datetime`. + sig { returns(T.nilable(String)) } + def timestamp; end + # The type of the bill_at. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # When this entry will be billed. + sig { returns(BillAt) } + def bill_at; end + # The amount to bill for this entry, in the smallest currency unit. + sig { returns(Integer) } + def value; end + def self.inner_class_types + @inner_class_types = {bill_at: BillAt} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {value: :int64_string} + end + end + class ProductDetails < ::Stripe::StripeObject + # The ID of the v1 Product. + sig { returns(String) } + def product; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # The resolved bill schedule for the fee. + sig { returns(T::Array[BillSchedule]) } + def bill_schedule; end + # The type of billable item that this fee references. + sig { returns(String) } + def billable_item_type; end + # Details for a product billable target. Set when `billable_item_type` is `product`. + sig { returns(T.nilable(ProductDetails)) } + def product_details; end + def self.inner_class_types + @inner_class_types = {bill_schedule: BillSchedule, product_details: ProductDetails} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = { + bill_schedule: { + kind: :array, + element: {kind: :object, fields: {value: :int64_string}}, + }, + } + end + end + class PricingLine < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Pricing < ::Stripe::StripeObject + class PriceDetails < ::Stripe::StripeObject + # The ID of the V1 price. + sig { returns(String) } + def price; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # V1 price details. Present when `type` is `price`. + sig { returns(T.nilable(PriceDetails)) } + def price_details; end + # The type of pricing. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {price_details: PriceDetails} + end + def self.field_remappings + @field_remappings = {} + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Resolved timestamp when the pricing line ends. + sig { returns(EndsAt) } + def ends_at; end + # The user-provided lookup key for the pricing line. + sig { returns(T.nilable(String)) } + def lookup_key; end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + # The pricing configuration for the pricing line. + sig { returns(Pricing) } + def pricing; end + # The ID of the pricing line. + sig { returns(String) } + def pricing_line; end + # Resolved timestamp when the pricing line starts. + sig { returns(StartsAt) } + def starts_at; end + def self.inner_class_types + @inner_class_types = {ends_at: EndsAt, pricing: Pricing, starts_at: StartsAt} + end + def self.field_remappings + @field_remappings = {} + end + end + class PricingOverride < ::Stripe::StripeObject + class EndsAt < ::Stripe::StripeObject + # The timestamp when the item ends. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Multiplier < ::Stripe::StripeObject + class Criterion < ::Stripe::StripeObject + class MetadataCondition < ::Stripe::StripeObject + class AllOf < ::Stripe::StripeObject + # The metadata key. + sig { returns(String) } + def key; end + # The metadata value. + sig { returns(String) } + def value; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # All of these key-value conditions must match. + sig { returns(T::Array[AllOf]) } + def all_of; end + def self.inner_class_types + @inner_class_types = {all_of: AllOf} + end + def self.field_remappings + @field_remappings = {} + end + end + # Filter by billable item IDs. + sig { returns(T::Array[String]) } + def billable_item_ids; end + # Filter by billable item lookup keys. + sig { returns(T::Array[String]) } + def billable_item_lookup_keys; end + # Filter by billable item type. + sig { returns(T::Array[String]) } + def billable_item_types; end + # Filter by metadata conditions. + sig { returns(T::Array[MetadataCondition]) } + def metadata_conditions; end + # Filter by rate card IDs. Only applicable for `multiplier` overrides. + sig { returns(T::Array[String]) } + def rate_card_ids; end + # Whether to include or exclude items matching these criteria. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {metadata_conditions: MetadataCondition} + end + def self.field_remappings + @field_remappings = {} + end + end + # Criteria determining which rates the multiplier applies to. + sig { returns(T::Array[Criterion]) } + def criteria; end + # The multiplier factor, represented as a decimal string. e.g. "0.8" for a 20% reduction. + sig { returns(String) } + def factor; end + def self.inner_class_types + @inner_class_types = {criteria: Criterion} + end + def self.field_remappings + @field_remappings = {} + end + end + class OverwritePrice < ::Stripe::StripeObject + class Tier < ::Stripe::StripeObject + # Price for the entire tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def flat_amount; end + # Per-unit price for units included in this tier, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + # Up to and including this quantity will be contained in the tier. + sig { returns(T.nilable(BigDecimal)) } + def up_to_decimal; end + # No upper bound to this tier. + sig { returns(T.nilable(String)) } + def up_to_inf; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {up_to_decimal: :decimal_string} + end + end + # The ID of the V1 price to overwrite. + sig { returns(String) } + def price; end + # Defines whether the tiered price should be graduated or volume-based. + sig { returns(T.nilable(String)) } + def tiering_mode; end + # Each element represents a pricing tier. + sig { returns(T::Array[Tier]) } + def tiers; end + # The per-unit amount to be charged, represented as a decimal string in minor currency units. + sig { returns(T.nilable(String)) } + def unit_amount; end + def self.inner_class_types + @inner_class_types = {tiers: Tier} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + } + end + end + class StartsAt < ::Stripe::StripeObject + # The timestamp when the item starts. + sig { returns(String) } + def timestamp; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Resolved timestamp when the pricing override ends. + sig { returns(EndsAt) } + def ends_at; end + # The user-provided lookup key for the pricing override. + sig { returns(T.nilable(String)) } + def lookup_key; end + # Details for a multiplier override. + sig { returns(T.nilable(Multiplier)) } + def multiplier; end + # Details for an overwrite_price override. + sig { returns(T.nilable(OverwritePrice)) } + def overwrite_price; end + # The ID of the pricing override. + sig { returns(String) } + def pricing_override; end + # The priority of this override relative to others. Lower number = higher priority. + sig { returns(Integer) } + def priority; end + # Resolved timestamp when the pricing override starts. + sig { returns(StartsAt) } + def starts_at; end + # The type of pricing override. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = { + ends_at: EndsAt, + multiplier: Multiplier, + overwrite_price: OverwritePrice, + starts_at: StartsAt, + } + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = { + overwrite_price: { + kind: :object, + fields: { + tiers: { + kind: :array, + element: {kind: :object, fields: {up_to_decimal: :decimal_string}}, + }, + }, + }, + } + end + end + class StatusDetails < ::Stripe::StripeObject + class Active < ::Stripe::StripeObject + # The timestamp when the contract was activated. + sig { returns(String) } + def activated_at; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class Canceled < ::Stripe::StripeObject + # The timestamp when the contract was canceled. + sig { returns(String) } + def canceled_at; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Details of the active contract status. + sig { returns(T.nilable(Active)) } + def active; end + # Details of the canceled contract status. + sig { returns(T.nilable(Canceled)) } + def canceled; end + def self.inner_class_types + @inner_class_types = {active: Active, canceled: Canceled} + end + def self.field_remappings + @field_remappings = {} + end + end + # The billing settings for the contract. + sig { returns(T.nilable(BillingSettings)) } + def billing_settings; end + # The contract line details of the contract. Only populated when `contract_line_details` is passed in the `include` parameter. + sig { returns(T::Array[ContractLineDetail]) } + def contract_line_details; end + # A unique user-provided contract number e.g. C-2026-0001. + sig { returns(String) } + def contract_number; end + # The computed total value of all contract lines. + sig { returns(ContractValueDetails) } + def contract_value_details; end + # Timestamp of when the object was created. + sig { returns(String) } + def created; end + # The currency of the contract. + sig { returns(String) } + def currency; end + # The ID of the customer associated with the contract. + sig { returns(String) } + def customer; end + # The ID of the contract object. + sig { returns(String) } + def id; end + # The license quantities of the contract. Only populated when `license_quantities` is passed in the `include` parameter. + sig { returns(T::Array[LicenseQuantity]) } + def license_quantities; end + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + sig { returns(T::Boolean) } + def livemode; end + # Set of key-value pairs that you can attach to an object. + sig { returns(T.nilable(T::Hash[String, String])) } + def metadata; end + # String representing the object's type. Objects of the same type share the same value of the object field. + sig { returns(String) } + def object; end + # The one-time fees of the contract. Only populated when `one_time_fees` is passed in the `include` parameter. + sig { returns(T.nilable(T::Array[OneTimeFee])) } + def one_time_fees; end + # The pricing lines of the contract. Only populated when `pricing_lines` is passed in the `include` parameter. + sig { returns(T::Array[PricingLine]) } + def pricing_lines; end + # The pricing overrides of the contract. Only populated when `pricing_overrides` is passed in the `include` parameter. + sig { returns(T::Array[PricingOverride]) } + def pricing_overrides; end + # The current status of the contract. + sig { returns(String) } + def status; end + # Information about the contract status transitions. + sig { returns(StatusDetails) } + def status_details; end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/resources/v2/billing/contract_license_pricing_quantity_change.rbi b/rbi/stripe/resources/v2/billing/contract_license_pricing_quantity_change.rbi new file mode 100644 index 000000000..04c31de51 --- /dev/null +++ b/rbi/stripe/resources/v2/billing/contract_license_pricing_quantity_change.rbi @@ -0,0 +1,40 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + # A license pricing quantity change object returned by ListContractLicenseQuantityChanges. + class ContractLicensePricingQuantityChange < APIResource + # The timestamp when this quantity change object was created. + sig { returns(String) } + def created; end + # The timestamp when this quantity change takes effect. + sig { returns(String) } + def effective_at; end + # The ID of the quantity change object. + sig { returns(String) } + def id; end + # The ID of the license pricing. + sig { returns(String) } + def license_pricing_id; end + # The type of the license pricing. + sig { returns(String) } + def license_pricing_type; end + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + sig { returns(T::Boolean) } + def livemode; end + # String representing the object's type. Objects of the same type share the same value of the object field. + sig { returns(String) } + def object; end + # The ID of the pricing line associated with this quantity change. + sig { returns(String) } + def pricing_line; end + # The quantity at the effective time. + sig { returns(Integer) } + def quantity; end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/resources/v2/data/reporting/query_run.rbi b/rbi/stripe/resources/v2/data/reporting/query_run.rbi index 50bf28c22..cd993065f 100644 --- a/rbi/stripe/resources/v2/data/reporting/query_run.rbi +++ b/rbi/stripe/resources/v2/data/reporting/query_run.rbi @@ -25,17 +25,34 @@ module Stripe @field_remappings = {} end end + class Schema < ::Stripe::StripeObject + # The name of the column. + sig { returns(String) } + def name; end + # The type of the column. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end # The content type of the file. sig { returns(String) } def content_type; end # A pre-signed URL that allows secure, time-limited access to download the file. sig { returns(DownloadUrl) } def download_url; end + # The columns of the schema. + sig { returns(T::Array[Schema]) } + def schema; end # The total size of the file in bytes. sig { returns(Integer) } def size; end def self.inner_class_types - @inner_class_types = {download_url: DownloadUrl} + @inner_class_types = {download_url: DownloadUrl, schema: Schema} end def self.field_remappings @field_remappings = {} diff --git a/rbi/stripe/resources/v2/reporting/report_run.rbi b/rbi/stripe/resources/v2/reporting/report_run.rbi index 1c8e94811..8c701d46e 100644 --- a/rbi/stripe/resources/v2/reporting/report_run.rbi +++ b/rbi/stripe/resources/v2/reporting/report_run.rbi @@ -25,17 +25,34 @@ module Stripe @field_remappings = {} end end + class Schema < ::Stripe::StripeObject + # The name of the column. + sig { returns(String) } + def name; end + # The type of the column. + sig { returns(String) } + def type; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end # The content type of the file. sig { returns(String) } def content_type; end # A pre-signed URL that allows secure, time-limited access to download the file. sig { returns(DownloadUrl) } def download_url; end + # The columns of the schema. + sig { returns(T::Array[Schema]) } + def schema; end # The total size of the file in bytes. sig { returns(Integer) } def size; end def self.inner_class_types - @inner_class_types = {download_url: DownloadUrl} + @inner_class_types = {download_url: DownloadUrl, schema: Schema} end def self.field_remappings @field_remappings = {} diff --git a/rbi/stripe/resources/v2/signals/account_signal.rbi b/rbi/stripe/resources/v2/signals/account_signal.rbi new file mode 100644 index 000000000..2ec6661e7 --- /dev/null +++ b/rbi/stripe/resources/v2/signals/account_signal.rbi @@ -0,0 +1,129 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Signals + # An automatically evaluated signal on a v2 account. + class AccountSignal < APIResource + class AccountDetails < ::Stripe::StripeObject + # The v2 account ID of the account. + sig { returns(T.nilable(String)) } + def account; end + # The v1 customer ID of the account, for users not yet migrated to v2/accounts. + sig { returns(T.nilable(String)) } + def customer; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + class FraudulentMerchant < ::Stripe::StripeObject + class Indicator < ::Stripe::StripeObject + # A brief explanation of how this indicator contributed to the fraudulent merchant probability. + sig { returns(String) } + def explanation; end + # The effect this indicator had on the overall risk level. + sig { returns(String) } + def impact; end + # The name of the specific indicator used in the risk assessment. + sig { returns(String) } + def indicator; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Array of objects representing individual factors that contributed to the calculated probability. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes indicators. + sig { returns(T::Array[Indicator]) } + def indicators; end + # The probability of the merchant being fraudulent. Can be between 0.00 and 100.00. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes numeric scores. + sig { returns(T.nilable(BigDecimal)) } + def probability; end + # Categorical assessment of the fraudulent merchant risk based on probability. + sig { returns(String) } + def risk_level; end + def self.inner_class_types + @inner_class_types = {indicators: Indicator} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {probability: :decimal_string} + end + end + class MerchantDelinquency < ::Stripe::StripeObject + class Indicator < ::Stripe::StripeObject + # A brief explanation of how this indicator contributed to the delinquency probability. + sig { returns(String) } + def explanation; end + # The effect this indicator had on the overall risk level. + sig { returns(String) } + def impact; end + # The name of the specific indicator used in the risk assessment. + sig { returns(String) } + def indicator; end + def self.inner_class_types + @inner_class_types = {} + end + def self.field_remappings + @field_remappings = {} + end + end + # Array of objects representing individual factors that contributed to the calculated probability of delinquency. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes indicators. + sig { returns(T::Array[Indicator]) } + def indicators; end + # The probability of delinquency. Can be between 0.00 and 100.00. Absent when risk level is not_assessed or unknown, + # or when the user is not on a product tier that includes numeric scores. + sig { returns(T.nilable(BigDecimal)) } + def probability; end + # Categorical assessment of the delinquency risk based on probability. + sig { returns(String) } + def risk_level; end + def self.inner_class_types + @inner_class_types = {indicators: Indicator} + end + def self.field_remappings + @field_remappings = {} + end + def self.field_encodings + @field_encodings = {probability: :decimal_string} + end + end + # The account or customer this signal is associated with. + sig { returns(T.nilable(AccountDetails)) } + def account_details; end + # Timestamp at which the signal was created. + sig { returns(String) } + def created; end + # Data for the fraudulent merchant signal. Present only when type is fraudulent_merchant. + sig { returns(T.nilable(FraudulentMerchant)) } + def fraudulent_merchant; end + # Unique identifier for the account signal. + sig { returns(String) } + def id; end + # Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + sig { returns(T::Boolean) } + def livemode; end + # Data for the merchant delinquency signal. Present only when type is merchant_delinquency. + sig { returns(T.nilable(MerchantDelinquency)) } + def merchant_delinquency; end + # String representing the object's type. Objects of the same type share the same value of the object field. + sig { returns(String) } + def object; end + # The type of signal. + sig { returns(String) } + def type; end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/delegated_checkout/order_service.rbi b/rbi/stripe/services/delegated_checkout/order_service.rbi new file mode 100644 index 000000000..4c25701a5 --- /dev/null +++ b/rbi/stripe/services/delegated_checkout/order_service.rbi @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module DelegatedCheckout + class OrderService < StripeService + # Retrieves a delegated checkout order. + sig { + params(order_id: String, params: T.any(::Stripe::DelegatedCheckout::OrderRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::DelegatedCheckout::Order) + } + def retrieve(order_id, params = {}, opts = {}); end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/delegated_checkout/requested_session_order_service.rbi b/rbi/stripe/services/delegated_checkout/requested_session_order_service.rbi new file mode 100644 index 000000000..1d8ffaa37 --- /dev/null +++ b/rbi/stripe/services/delegated_checkout/requested_session_order_service.rbi @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module DelegatedCheckout + class RequestedSessionOrderService < StripeService + # Lists orders for a delegated checkout requested session. + sig { + params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionOrderListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) + } + def list(requested_session, params = {}, opts = {}); end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/delegated_checkout/requested_session_service.rbi b/rbi/stripe/services/delegated_checkout/requested_session_service.rbi index 247771df6..f6e9a9acd 100644 --- a/rbi/stripe/services/delegated_checkout/requested_session_service.rbi +++ b/rbi/stripe/services/delegated_checkout/requested_session_service.rbi @@ -5,6 +5,7 @@ module Stripe module DelegatedCheckout class RequestedSessionService < StripeService + attr_reader :orders # Confirms a requested session sig { params(requested_session: String, params: T.any(::Stripe::DelegatedCheckout::RequestedSessionConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::DelegatedCheckout::RequestedSession) diff --git a/rbi/stripe/services/delegated_checkout_service.rbi b/rbi/stripe/services/delegated_checkout_service.rbi index 6593b1eb0..7fcfcf0d9 100644 --- a/rbi/stripe/services/delegated_checkout_service.rbi +++ b/rbi/stripe/services/delegated_checkout_service.rbi @@ -4,6 +4,7 @@ # typed: true module Stripe class DelegatedCheckoutService < StripeService + attr_reader :orders attr_reader :requested_sessions end end \ No newline at end of file diff --git a/rbi/stripe/services/payment_location_capability_service.rbi b/rbi/stripe/services/payment_location_capability_service.rbi index 278d4feb8..352c5ec8a 100644 --- a/rbi/stripe/services/payment_location_capability_service.rbi +++ b/rbi/stripe/services/payment_location_capability_service.rbi @@ -4,19 +4,19 @@ # typed: true module Stripe class PaymentLocationCapabilityService < StripeService - # Returns a list of PaymentLocationCapability objects associated with the location. + # List all payment location capabilities associated with the payment location. sig { params(params: T.any(::Stripe::PaymentLocationCapabilityListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::ListObject) } def list(params = {}, opts = {}); end - # Retrieves information about the specified Payment Location Capability. + # Retrieves a payment_location capability sig { params(capability: String, params: T.any(::Stripe::PaymentLocationCapabilityRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::PaymentLocationCapability) } def retrieve(capability, params = {}, opts = {}); end - # Updates a specified Payment Location Capability. Request or remove a payment location capability by updating its requested parameter. + # Updates a payment_location capability. Request or remove a payment_location capability by updating its requested parameter. sig { params(capability: String, params: T.any(::Stripe::PaymentLocationCapabilityUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::PaymentLocationCapability) } diff --git a/rbi/stripe/services/v2/billing/contract_service.rbi b/rbi/stripe/services/v2/billing/contract_service.rbi new file mode 100644 index 000000000..cab89cb5b --- /dev/null +++ b/rbi/stripe/services/v2/billing/contract_service.rbi @@ -0,0 +1,48 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + class ContractService < StripeService + attr_reader :license_pricing + # Activate a Draft Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractActivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def activate(id, params = {}, opts = {}); end + + # Cancel a Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractCancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def cancel(id, params = {}, opts = {}); end + + # Create a Contract object. + sig { + params(params: T.any(::Stripe::V2::Billing::ContractCreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def create(params = {}, opts = {}); end + + # List Contract objects with pagination. + sig { + params(params: T.any(::Stripe::V2::Billing::ContractListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::ListObject) + } + def list(params = {}, opts = {}); end + + # Retrieve a Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def retrieve(id, params = {}, opts = {}); end + + # Update a Contract object by ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Billing::ContractUpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Billing::Contract) + } + def update(id, params = {}, opts = {}); end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/v2/billing/contracts/license_pricing/quantity_change_service.rbi b/rbi/stripe/services/v2/billing/contracts/license_pricing/quantity_change_service.rbi new file mode 100644 index 000000000..953a27698 --- /dev/null +++ b/rbi/stripe/services/v2/billing/contracts/license_pricing/quantity_change_service.rbi @@ -0,0 +1,21 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + module Contracts + module LicensePricing + class QuantityChangeService < StripeService + # List license quantity changes for a contract given a license pricing ID. + sig { + params(contract_id: String, license_pricing_id: String, params: T.any(::Stripe::V2::Billing::Contracts::LicensePricing::QuantityChangeListQuantityChangesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::ListObject) + } + def list_quantity_changes(contract_id, license_pricing_id, params = {}, opts = {}); end + end + end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/v2/billing/contracts/license_pricing_service.rbi b/rbi/stripe/services/v2/billing/contracts/license_pricing_service.rbi new file mode 100644 index 000000000..fcd06759e --- /dev/null +++ b/rbi/stripe/services/v2/billing/contracts/license_pricing_service.rbi @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Billing + module Contracts + class LicensePricingService < StripeService + attr_reader :quantity_changes + end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/v2/billing_service.rbi b/rbi/stripe/services/v2/billing_service.rbi index 1ffd50f41..a45c60401 100644 --- a/rbi/stripe/services/v2/billing_service.rbi +++ b/rbi/stripe/services/v2/billing_service.rbi @@ -8,6 +8,7 @@ module Stripe attr_reader :bill_settings attr_reader :cadences attr_reader :collection_settings + attr_reader :contracts attr_reader :custom_pricing_units attr_reader :intents attr_reader :license_fees diff --git a/rbi/stripe/services/v2/payment_service.rbi b/rbi/stripe/services/v2/payments_service.rbi similarity index 83% rename from rbi/stripe/services/v2/payment_service.rbi rename to rbi/stripe/services/v2/payments_service.rbi index 76a96965b..59c9c589e 100644 --- a/rbi/stripe/services/v2/payment_service.rbi +++ b/rbi/stripe/services/v2/payments_service.rbi @@ -4,7 +4,7 @@ # typed: true module Stripe module V2 - class PaymentService < StripeService + class PaymentsService < StripeService attr_reader :off_session_payments attr_reader :settlement_allocation_intents end diff --git a/rbi/stripe/services/v2/signals/account_signal_service.rbi b/rbi/stripe/services/v2/signals/account_signal_service.rbi new file mode 100644 index 000000000..320617b9c --- /dev/null +++ b/rbi/stripe/services/v2/signals/account_signal_service.rbi @@ -0,0 +1,23 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + module Signals + class AccountSignalService < StripeService + # Lists AccountSignals for a given account or customer, filtered by signal type. + sig { + params(params: T.any(::Stripe::V2::Signals::AccountSignalListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::ListObject) + } + def list(params = {}, opts = {}); end + + # Retrieves an AccountSignal by its ID. + sig { + params(id: String, params: T.any(::Stripe::V2::Signals::AccountSignalRetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(::Stripe::V2::Signals::AccountSignal) + } + def retrieve(id, params = {}, opts = {}); end + end + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/v2/signals_service.rbi b/rbi/stripe/services/v2/signals_service.rbi new file mode 100644 index 000000000..fbe51ac4a --- /dev/null +++ b/rbi/stripe/services/v2/signals_service.rbi @@ -0,0 +1,11 @@ +# File generated from our OpenAPI spec +# frozen_string_literal: true + +# typed: true +module Stripe + module V2 + class SignalsService < StripeService + attr_reader :account_signals + end + end +end \ No newline at end of file diff --git a/rbi/stripe/services/v2_services.rbi b/rbi/stripe/services/v2_services.rbi index 9432d625f..78204eae6 100644 --- a/rbi/stripe/services/v2_services.rbi +++ b/rbi/stripe/services/v2_services.rbi @@ -15,6 +15,7 @@ module Stripe attr_reader :orchestrated_commerce attr_reader :payments attr_reader :reporting + attr_reader :signals attr_reader :tax attr_reader :test_helpers end diff --git a/rbi/stripe/stripe_event_notification_handler.rbi b/rbi/stripe/stripe_event_notification_handler.rbi index cc0a4e396..b8d0e66e6 100644 --- a/rbi/stripe/stripe_event_notification_handler.rbi +++ b/rbi/stripe/stripe_event_notification_handler.rbi @@ -2473,6 +2473,12 @@ module Stripe def on_v2_signals_account_signal_fraudulent_merchant_ready(&blk); end + sig do + params(blk: T.proc.params(event_notification: ::Stripe::Events::V2SignalsAccountSignalMerchantDelinquencyReadyEventNotification, client: ::Stripe::StripeClient).void).void + end + def on_v2_signals_account_signal_merchant_delinquency_ready(&blk); + end + # event-handler-methods: The end of the section generated from our OpenAPI spec end diff --git a/test/stripe/api_requestor_test.rb b/test/stripe/api_requestor_test.rb index 3d0620081..d240397ee 100644 --- a/test/stripe/api_requestor_test.rb +++ b/test/stripe/api_requestor_test.rb @@ -1312,6 +1312,29 @@ class RequestorTest < Test::Unit::TestCase end context "#execute_request" do + context "Stripe-Notice header" do + should "emit a warning when the header is present" do + stub_request(:post, "#{Stripe::DEFAULT_API_BASE}/v1/charges") + .to_return( + body: JSON.generate(object: "charge"), + headers: { "Stripe-Notice" => "This is a notice" } + ) + + requestor = APIRequestor.new("sk_test_123") + requestor.expects(:warn).with("WARNING: This is a notice") + requestor.execute_request(:post, "/v1/charges", :api) + end + + should "not emit a warning when the header is absent" do + stub_request(:post, "#{Stripe::DEFAULT_API_BASE}/v1/charges") + .to_return(body: JSON.generate(object: "charge")) + + requestor = APIRequestor.new("sk_test_123") + requestor.expects(:warn).never + requestor.execute_request(:post, "/v1/charges", :api) + end + end + should "handle success response with empty body" do stub_request(:post, "#{Stripe::DEFAULT_API_BASE}/v1/charges") .to_return(body: "", status: 200) diff --git a/test/stripe/generated_examples_test.rb b/test/stripe/generated_examples_test.rb index bb5a50d4a..fd16b3210 100644 --- a/test/stripe/generated_examples_test.rb +++ b/test/stripe/generated_examples_test.rb @@ -7778,6 +7778,244 @@ class CodegennedExampleTest < Test::Unit::TestCase ) assert_requested :get, "#{Stripe::DEFAULT_API_BASE}/v2/billing/collection_settings/collection_setting_id_123/versions/id_123" end + should "Test v2 billing contract get (service)" do + stub_request(:get, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts").to_return( + body: '{"data":[{"object":"v2.billing.contract","contract_line_details":[{"contract_line":"contract_line","contract_line_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"service_action"}],"pricing":{},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"contract_number":"contract_number","contract_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","currency":"usd","customer":"customer","id":"obj_123","license_quantities":[{"license_pricing_id":"license_pricing_id","license_pricing_type":"price","pricing_line":"pricing_line","quantity":1285004149}],"livemode":true,"pricing_lines":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing":{"type":"price"},"pricing_line":"pricing_line","starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"pricing_overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing_override":"pricing_override","priority":1165461084,"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"multiplier"}],"status":"draft","status_details":{}}],"next_page_url":null,"previous_page_url":null}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + contracts = client.v2.billing.contracts.list + assert_requested :get, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts" + end + should "Test v2 billing contract post (service)" do + stub_request(:post, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts").to_return( + body: '{"object":"v2.billing.contract","contract_line_details":[{"contract_line":"contract_line","contract_line_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"service_action"}],"pricing":{},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"contract_number":"contract_number","contract_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","currency":"usd","customer":"customer","id":"obj_123","license_quantities":[{"license_pricing_id":"license_pricing_id","license_pricing_type":"price","pricing_line":"pricing_line","quantity":1285004149}],"livemode":true,"pricing_lines":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing":{"type":"price"},"pricing_line":"pricing_line","starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"pricing_overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing_override":"pricing_override","priority":1165461084,"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"multiplier"}],"status":"draft","status_details":{}}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + contract = client.v2.billing.contracts.create({ + contract_lines: [ + { + ends_at: { timestamp: "1970-01-01T15:18:46.294Z" }, + metadata: { key: "metadata" }, + overrides: [ + { + ends_at: { timestamp: "1970-01-01T15:18:46.294Z" }, + service_action: { + add: { + credit_grant: { + amount: { + monetary: { + currency: "USD", + value: 63, + }, + type: "monetary", + }, + applicability_config: { + scope: { + billable_items: ["billable_items"], + price_type: "metered", + }, + }, + category: "paid", + expiry_config: { type: "end_of_service_period" }, + name: "name", + priority: 1_165_461_084, + }, + service_interval: "month", + service_interval_count: 1_375_336_415, + type: "credit_grant", + }, + replace: { + credit_grant: { + amount: { + monetary: { + currency: "USD", + value: 63, + }, + type: "monetary", + }, + applicability_config: { + scope: { + billable_items: ["billable_items"], + price_type: "metered", + }, + }, + category: "paid", + expiry_config: { type: "end_of_service_period" }, + name: "name", + priority: 1_165_461_084, + }, + id: "obj_123", + lookup_key: "lookup_key", + service_interval: "month", + service_interval_count: 1_375_336_415, + type: "credit_grant", + }, + type: "add", + }, + starts_at: { timestamp: "1970-01-01T15:18:46.294Z" }, + type: "service_action", + }, + ], + pricing: {}, + starts_at: { timestamp: "1970-01-01T15:18:46.294Z" }, + }, + ], + contract_number: "contract_number", + currency: "usd", + license_quantity_actions: [ + { + effective_at: { + timestamp: "1970-01-01T15:18:46.294Z", + type: "timestamp", + }, + license_pricing_id: "license_pricing_id", + license_pricing_lookup_key: "license_pricing_lookup_key", + license_pricing_type: "price", + pricing_line: "pricing_line", + set: { quantity: 1_285_004_149 }, + type: "set", + }, + ], + pricing_lines: [ + { + ends_at: { + timestamp: "1970-01-01T15:18:46.294Z", + type: "contract_end", + }, + lookup_key: "lookup_key", + metadata: { key: "metadata" }, + pricing: { + price_details: { + price: "price", + quantity: 1_285_004_149, + }, + type: "price", + }, + starts_at: { + timestamp: "1970-01-01T15:18:46.294Z", + type: "contract_start", + }, + }, + ], + pricing_overrides: [ + { + ends_at: { + timestamp: "1970-01-01T15:18:46.294Z", + type: "contract_end", + }, + lookup_key: "lookup_key", + multiplier: { + criteria: [ + { + billable_item_ids: ["billable_item_ids"], + billable_item_lookup_keys: ["billable_item_lookup_keys"], + billable_item_types: ["metered"], + metadata_conditions: [ + { + all_of: [ + { + key: "key", + value: "value", + }, + ], + }, + ], + rate_card_ids: ["rate_card_ids"], + type: "exclude", + }, + ], + factor: "factor", + }, + overwrite_price: { + price: "price", + tiering_mode: "graduated", + tiers: [ + { + flat_amount: "flat_amount", + unit_amount: "unit_amount", + up_to_decimal: "1387931359.3333333", + up_to_inf: "inf", + }, + ], + unit_amount: "unit_amount", + }, + priority: 1_165_461_084, + starts_at: { + timestamp: "1970-01-01T15:18:46.294Z", + type: "contract_start", + }, + type: "multiplier", + }, + ], + }) + assert_requested :post, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts" + end + should "Test v2 billing contract get 2 (service)" do + stub_request(:get, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123").to_return( + body: '{"object":"v2.billing.contract","contract_line_details":[{"contract_line":"contract_line","contract_line_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"service_action"}],"pricing":{},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"contract_number":"contract_number","contract_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","currency":"usd","customer":"customer","id":"obj_123","license_quantities":[{"license_pricing_id":"license_pricing_id","license_pricing_type":"price","pricing_line":"pricing_line","quantity":1285004149}],"livemode":true,"pricing_lines":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing":{"type":"price"},"pricing_line":"pricing_line","starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"pricing_overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing_override":"pricing_override","priority":1165461084,"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"multiplier"}],"status":"draft","status_details":{}}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + contract = client.v2.billing.contracts.retrieve("id_123") + assert_requested :get, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123" + end + should "Test v2 billing contract post 2 (service)" do + stub_request(:post, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123").to_return( + body: '{"object":"v2.billing.contract","contract_line_details":[{"contract_line":"contract_line","contract_line_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"service_action"}],"pricing":{},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"contract_number":"contract_number","contract_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","currency":"usd","customer":"customer","id":"obj_123","license_quantities":[{"license_pricing_id":"license_pricing_id","license_pricing_type":"price","pricing_line":"pricing_line","quantity":1285004149}],"livemode":true,"pricing_lines":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing":{"type":"price"},"pricing_line":"pricing_line","starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"pricing_overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing_override":"pricing_override","priority":1165461084,"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"multiplier"}],"status":"draft","status_details":{}}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + contract = client.v2.billing.contracts.update("id_123") + assert_requested :post, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123" + end + should "Test v2 billing contract post 3 (service)" do + stub_request( + :post, + "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123/activate" + ).to_return( + body: '{"object":"v2.billing.contract","contract_line_details":[{"contract_line":"contract_line","contract_line_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"service_action"}],"pricing":{},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"contract_number":"contract_number","contract_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","currency":"usd","customer":"customer","id":"obj_123","license_quantities":[{"license_pricing_id":"license_pricing_id","license_pricing_type":"price","pricing_line":"pricing_line","quantity":1285004149}],"livemode":true,"pricing_lines":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing":{"type":"price"},"pricing_line":"pricing_line","starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"pricing_overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing_override":"pricing_override","priority":1165461084,"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"multiplier"}],"status":"draft","status_details":{}}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + contract = client.v2.billing.contracts.activate("id_123") + assert_requested :post, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123/activate" + end + should "Test v2 billing contract post 4 (service)" do + stub_request( + :post, + "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123/cancel" + ).to_return( + body: '{"object":"v2.billing.contract","contract_line_details":[{"contract_line":"contract_line","contract_line_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"service_action"}],"pricing":{},"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"contract_number":"contract_number","contract_value_details":{"total":"total"},"created":"1970-01-12T21:42:34.472Z","currency":"usd","customer":"customer","id":"obj_123","license_quantities":[{"license_pricing_id":"license_pricing_id","license_pricing_type":"price","pricing_line":"pricing_line","quantity":1285004149}],"livemode":true,"pricing_lines":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing":{"type":"price"},"pricing_line":"pricing_line","starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"}}],"pricing_overrides":[{"ends_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"pricing_override":"pricing_override","priority":1165461084,"starts_at":{"timestamp":"1970-01-01T15:18:46.294Z"},"type":"multiplier"}],"status":"draft","status_details":{}}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + contract = client.v2.billing.contracts.cancel("id_123") + assert_requested :post, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/id_123/cancel" + end + should "Test v2 billing contracts license pricing quantity change get (service)" do + stub_request( + :get, + "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/contract_id_123/license_pricing/license_pricing_id_123/quantity_changes" + ).to_return( + body: '{"data":[{"object":"v2.billing.contract_license_pricing_quantity_change","created":"1970-01-12T21:42:34.472Z","effective_at":"1970-01-03T20:38:28.043Z","id":"obj_123","license_pricing_id":"license_pricing_id","license_pricing_type":"price","livemode":true,"pricing_line":"pricing_line","quantity":1285004149}],"next_page_url":null,"previous_page_url":null}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + contract_license_pricing_quantity_changes = client.v2.billing.contracts.license_pricing.quantity_changes.list_quantity_changes( + "contract_id_123", + "license_pricing_id_123" + ) + assert_requested :get, "#{Stripe::DEFAULT_API_BASE}/v2/billing/contracts/contract_id_123/license_pricing/license_pricing_id_123/quantity_changes" + end should "Test v2 billing custom pricing unit get (service)" do stub_request(:get, "#{Stripe::DEFAULT_API_BASE}/v2/billing/custom_pricing_units").to_return( body: '{"data":[{"object":"v2.billing.custom_pricing_unit","active":true,"created":"1970-01-12T21:42:34.472Z","display_name":"display_name","id":"obj_123","livemode":true}],"next_page_url":null,"previous_page_url":null}', @@ -10978,6 +11216,29 @@ class CodegennedExampleTest < Test::Unit::TestCase report_run = client.v2.reporting.report_runs.retrieve("id_123") assert_requested :get, "#{Stripe::DEFAULT_API_BASE}/v2/reporting/report_runs/id_123" end + should "Test v2 signals account signal get (service)" do + stub_request( + :get, + "#{Stripe::DEFAULT_API_BASE}/v2/signals/account_signals?type[0]=fraudulent_merchant" + ).to_return( + body: '{"data":[{"object":"v2.signals.account_signal","created":"1970-01-12T21:42:34.472Z","id":"obj_123","livemode":true,"type":"fraudulent_merchant"}],"next_page_url":null,"previous_page_url":null}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + account_signals = client.v2.signals.account_signals.list({ type: ["fraudulent_merchant"] }) + assert_requested :get, "#{Stripe::DEFAULT_API_BASE}/v2/signals/account_signals?type[0]=fraudulent_merchant" + end + should "Test v2 signals account signal get 2 (service)" do + stub_request(:get, "#{Stripe::DEFAULT_API_BASE}/v2/signals/account_signals/id_123").to_return( + body: '{"object":"v2.signals.account_signal","created":"1970-01-12T21:42:34.472Z","id":"obj_123","livemode":true,"type":"fraudulent_merchant"}', + status: 200 + ) + client = Stripe::StripeClient.new("sk_test_123") + + account_signal = client.v2.signals.account_signals.retrieve("id_123") + assert_requested :get, "#{Stripe::DEFAULT_API_BASE}/v2/signals/account_signals/id_123" + end should "Test v2 tax manual rule get (service)" do stub_request(:get, "#{Stripe::DEFAULT_API_BASE}/v2/tax/manual_rules").to_return( body: '{"data":[{"object":"v2.tax.manual_rule","created":"1970-01-12T21:42:34.472Z","id":"obj_123","livemode":true,"products":[{"type":"licensed_item"}],"scheduled_tax_rates":[{"rates":[{"display_name":"display_name","percentage":"614555204"}]}],"status":"active"}],"next_page_url":null,"previous_page_url":null}',