stripe 13.5.0 → 14.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +33 -3
- data/Gemfile +4 -0
- data/OPENAPI_VERSION +1 -1
- data/README.md +29 -0
- data/VERSION +1 -1
- data/lib/stripe/api_operations/request.rb +1 -0
- data/lib/stripe/api_requestor.rb +3 -0
- data/lib/stripe/api_version.rb +1 -1
- data/lib/stripe/errors.rb +0 -7
- data/lib/stripe/object_types.rb +8 -2
- data/lib/stripe/request_params.rb +24 -0
- data/lib/stripe/resources/account.rb +4634 -0
- data/lib/stripe/resources/account_link.rb +54 -0
- data/lib/stripe/resources/account_session.rb +739 -0
- data/lib/stripe/resources/apple_pay_domain.rb +54 -0
- data/lib/stripe/resources/application.rb +20 -0
- data/lib/stripe/resources/application_fee.rb +87 -0
- data/lib/stripe/resources/application_fee_refund.rb +17 -0
- data/lib/stripe/resources/apps/secret.rb +141 -0
- data/lib/stripe/resources/balance.rb +122 -0
- data/lib/stripe/resources/balance_transaction.rb +103 -0
- data/lib/stripe/resources/bank_account.rb +84 -2
- data/lib/stripe/resources/billing/alert.rb +135 -0
- data/lib/stripe/resources/billing/alert_triggered.rb +26 -0
- data/lib/stripe/resources/billing/credit_balance_summary.rb +40 -0
- data/lib/stripe/resources/billing/credit_balance_transaction.rb +107 -0
- data/lib/stripe/resources/billing/credit_grant.rb +217 -0
- data/lib/stripe/resources/billing/meter.rb +169 -0
- data/lib/stripe/resources/billing/meter_event.rb +35 -0
- data/lib/stripe/resources/billing/meter_event_adjustment.rb +43 -0
- data/lib/stripe/resources/billing/meter_event_summary.rb +15 -0
- data/lib/stripe/resources/billing_portal/configuration.rb +553 -0
- data/lib/stripe/resources/billing_portal/session.rb +271 -0
- data/lib/stripe/resources/capability.rb +84 -0
- data/lib/stripe/resources/card.rb +77 -0
- data/lib/stripe/resources/cash_balance.rb +17 -0
- data/lib/stripe/resources/charge.rb +1612 -0
- data/lib/stripe/resources/checkout/session.rb +3530 -6
- data/lib/stripe/resources/climate/order.rb +167 -0
- data/lib/stripe/resources/climate/product.rb +47 -0
- data/lib/stripe/resources/climate/supplier.rb +45 -0
- data/lib/stripe/resources/confirmation_token.rb +1448 -0
- data/lib/stripe/resources/connect_collection_transfer.rb +24 -0
- data/lib/stripe/resources/country_spec.rb +54 -0
- data/lib/stripe/resources/coupon.rb +189 -0
- data/lib/stripe/resources/credit_note.rb +639 -0
- data/lib/stripe/resources/credit_note_line_item.rb +67 -0
- data/lib/stripe/resources/customer.rb +824 -0
- data/lib/stripe/resources/customer_balance_transaction.rb +29 -0
- data/lib/stripe/resources/customer_cash_balance_transaction.rb +109 -0
- data/lib/stripe/resources/customer_session.rb +159 -0
- data/lib/stripe/resources/discount.rb +29 -0
- data/lib/stripe/resources/dispute.rb +610 -0
- data/lib/stripe/resources/entitlements/active_entitlement.rb +37 -0
- data/lib/stripe/resources/entitlements/active_entitlement_summary.rb +23 -0
- data/lib/stripe/resources/entitlements/feature.rb +81 -0
- data/lib/stripe/resources/ephemeral_key.rb +21 -0
- data/lib/stripe/resources/event.rb +90 -0
- data/lib/stripe/resources/exchange_rate.rb +24 -0
- data/lib/stripe/resources/file.rb +102 -0
- data/lib/stripe/resources/file_link.rb +103 -0
- data/lib/stripe/resources/financial_connections/account.rb +237 -0
- data/lib/stripe/resources/financial_connections/account_owner.rb +17 -0
- data/lib/stripe/resources/financial_connections/account_ownership.rb +9 -0
- data/lib/stripe/resources/financial_connections/session.rb +95 -0
- data/lib/stripe/resources/financial_connections/transaction.rb +92 -0
- data/lib/stripe/resources/forwarding/request.rb +156 -0
- data/lib/stripe/resources/funding_instructions.rb +308 -0
- data/lib/stripe/resources/identity/verification_report.rb +257 -0
- data/lib/stripe/resources/identity/verification_session.rb +352 -0
- data/lib/stripe/resources/invoice.rb +3204 -21
- data/lib/stripe/resources/invoice_item.rb +400 -0
- data/lib/stripe/resources/invoice_line_item.rb +350 -0
- data/lib/stripe/resources/invoice_payment.rb +105 -0
- data/lib/stripe/resources/invoice_rendering_template.rb +55 -0
- data/lib/stripe/resources/issuing/authorization.rb +1104 -0
- data/lib/stripe/resources/issuing/card.rb +657 -0
- data/lib/stripe/resources/issuing/cardholder.rb +648 -0
- data/lib/stripe/resources/issuing/dispute.rb +781 -0
- data/lib/stripe/resources/issuing/personalization_design.rb +276 -0
- data/lib/stripe/resources/issuing/physical_bundle.rb +54 -0
- data/lib/stripe/resources/issuing/token.rb +166 -0
- data/lib/stripe/resources/issuing/transaction.rb +912 -0
- data/lib/stripe/resources/line_item.rb +47 -0
- data/lib/stripe/resources/login_link.rb +7 -0
- data/lib/stripe/resources/mandate.rb +142 -0
- data/lib/stripe/resources/payment_intent.rb +8650 -0
- data/lib/stripe/resources/payment_link.rb +1632 -0
- data/lib/stripe/resources/payment_method.rb +1542 -0
- data/lib/stripe/resources/payment_method_configuration.rb +2776 -0
- data/lib/stripe/resources/payment_method_domain.rb +150 -6
- data/lib/stripe/resources/payout.rb +209 -0
- data/lib/stripe/resources/person.rb +264 -1
- data/lib/stripe/resources/plan.rb +302 -0
- data/lib/stripe/resources/price.rb +605 -1
- data/lib/stripe/resources/product.rb +472 -0
- data/lib/stripe/resources/product_feature.rb +12 -0
- data/lib/stripe/resources/promotion_code.rb +212 -0
- data/lib/stripe/resources/quote.rb +917 -0
- data/lib/stripe/resources/radar/early_fraud_warning.rb +68 -0
- data/lib/stripe/resources/radar/value_list.rb +116 -0
- data/lib/stripe/resources/radar/value_list_item.rb +86 -0
- data/lib/stripe/resources/refund.rb +392 -0
- data/lib/stripe/resources/reporting/report_run.rb +141 -0
- data/lib/stripe/resources/reporting/report_type.rb +27 -0
- data/lib/stripe/resources/reserve_transaction.rb +22 -0
- data/lib/stripe/resources/reversal.rb +21 -0
- data/lib/stripe/resources/review.rb +99 -0
- data/lib/stripe/resources/setup_attempt.rb +368 -0
- data/lib/stripe/resources/setup_intent.rb +3473 -0
- data/lib/stripe/resources/shipping_rate.rb +250 -0
- data/lib/stripe/resources/sigma/scheduled_query_run.rb +45 -0
- data/lib/stripe/resources/source.rb +1198 -0
- data/lib/stripe/resources/source_mandate_notification.rb +66 -0
- data/lib/stripe/resources/source_transaction.rb +85 -0
- data/lib/stripe/resources/subscription.rb +1686 -0
- data/lib/stripe/resources/subscription_item.rb +313 -5
- data/lib/stripe/resources/subscription_schedule.rb +1281 -0
- data/lib/stripe/resources/tax/calculation.rb +378 -0
- data/lib/stripe/resources/tax/calculation_line_item.rb +56 -0
- data/lib/stripe/resources/tax/registration.rb +2373 -0
- data/lib/stripe/resources/tax/settings.rb +117 -0
- data/lib/stripe/resources/tax/transaction.rb +258 -0
- data/lib/stripe/resources/tax/transaction_line_item.rb +31 -0
- data/lib/stripe/resources/tax_code.rb +26 -0
- data/lib/stripe/resources/tax_deducted_at_source.rb +22 -0
- data/lib/stripe/resources/tax_id.rb +112 -0
- data/lib/stripe/resources/tax_rate.rb +191 -0
- data/lib/stripe/resources/terminal/configuration.rb +1260 -0
- data/lib/stripe/resources/terminal/connection_token.rb +18 -0
- data/lib/stripe/resources/terminal/location.rb +166 -0
- data/lib/stripe/resources/terminal/reader.rb +427 -0
- data/lib/stripe/resources/test_helpers/test_clock.rb +77 -0
- data/lib/stripe/resources/token.rb +1159 -0
- data/lib/stripe/resources/topup.rb +165 -0
- data/lib/stripe/resources/transfer.rb +144 -0
- data/lib/stripe/resources/treasury/credit_reversal.rb +83 -0
- data/lib/stripe/resources/treasury/debit_reversal.rb +94 -0
- data/lib/stripe/resources/treasury/financial_account.rb +725 -1
- data/lib/stripe/resources/treasury/financial_account_features.rb +189 -0
- data/lib/stripe/resources/treasury/inbound_transfer.rb +226 -0
- data/lib/stripe/resources/treasury/outbound_payment.rb +486 -0
- data/lib/stripe/resources/treasury/outbound_transfer.rb +341 -0
- data/lib/stripe/resources/treasury/received_credit.rb +237 -0
- data/lib/stripe/resources/treasury/received_debit.rb +196 -0
- data/lib/stripe/resources/treasury/transaction.rb +167 -0
- data/lib/stripe/resources/treasury/transaction_entry.rb +148 -0
- data/lib/stripe/resources/v2/amount.rb +9 -0
- data/lib/stripe/resources/v2/billing/meter_event.rb +18 -0
- data/lib/stripe/resources/v2/billing/meter_event_adjustment.rb +21 -0
- data/lib/stripe/resources/v2/billing/meter_event_session.rb +14 -0
- data/lib/stripe/resources/v2/event.rb +28 -0
- data/lib/stripe/resources/v2/event_destination.rb +60 -0
- data/lib/stripe/resources/webhook_endpoint.rb +113 -0
- data/lib/stripe/resources.rb +8 -2
- data/lib/stripe/services/account_capability_service.rb +32 -0
- data/lib/stripe/services/account_external_account_service.rb +250 -0
- data/lib/stripe/services/account_link_service.rb +46 -0
- data/lib/stripe/services/account_login_link_service.rb +9 -0
- data/lib/stripe/services/account_person_service.rb +875 -0
- data/lib/stripe/services/account_service.rb +4000 -0
- data/lib/stripe/services/account_session_service.rb +484 -0
- data/lib/stripe/services/apple_pay_domain_service.rb +51 -0
- data/lib/stripe/services/application_fee_refund_service.rb +54 -0
- data/lib/stripe/services/application_fee_service.rb +57 -0
- data/lib/stripe/services/apps/secret_service.rb +116 -0
- data/lib/stripe/services/balance_service.rb +9 -0
- data/lib/stripe/services/balance_transaction_service.rb +69 -0
- data/lib/stripe/services/billing/alert_service.rb +113 -0
- data/lib/stripe/services/billing/credit_balance_summary_service.rb +48 -0
- data/lib/stripe/services/billing/credit_balance_transaction_service.rb +40 -0
- data/lib/stripe/services/billing/credit_grant_service.rb +166 -0
- data/lib/stripe/services/billing/meter_event_adjustment_service.rb +26 -0
- data/lib/stripe/services/billing/meter_event_service.rb +21 -0
- data/lib/stripe/services/billing/meter_event_summary_service.rb +39 -0
- data/lib/stripe/services/billing/meter_service.rb +130 -0
- data/lib/stripe/services/billing_portal/configuration_service.rb +444 -0
- data/lib/stripe/services/billing_portal/session_service.rb +173 -0
- data/lib/stripe/services/charge_service.rb +402 -0
- data/lib/stripe/services/checkout/session_line_item_service.rb +18 -0
- data/lib/stripe/services/checkout/session_service.rb +2399 -5
- data/lib/stripe/services/climate/order_service.rb +102 -0
- data/lib/stripe/services/climate/product_service.rb +27 -0
- data/lib/stripe/services/climate/supplier_service.rb +27 -0
- data/lib/stripe/services/confirmation_token_service.rb +9 -0
- data/lib/stripe/services/country_spec_service.rb +27 -0
- data/lib/stripe/services/coupon_service.rb +152 -0
- data/lib/stripe/services/credit_note_line_item_service.rb +18 -0
- data/lib/stripe/services/credit_note_preview_lines_service.rb +152 -0
- data/lib/stripe/services/credit_note_service.rb +365 -0
- data/lib/stripe/services/customer_balance_transaction_service.rb +63 -0
- data/lib/stripe/services/customer_cash_balance_service.rb +29 -0
- data/lib/stripe/services/customer_cash_balance_transaction_service.rb +27 -0
- data/lib/stripe/services/customer_funding_instructions_service.rb +42 -0
- data/lib/stripe/services/customer_payment_method_service.rb +40 -0
- data/lib/stripe/services/customer_payment_source_service.rb +179 -0
- data/lib/stripe/services/customer_service.rb +577 -0
- data/lib/stripe/services/customer_session_service.rb +96 -0
- data/lib/stripe/services/customer_tax_id_service.rb +45 -0
- data/lib/stripe/services/dispute_service.rb +374 -0
- data/lib/stripe/services/entitlements/active_entitlement_service.rb +36 -0
- data/lib/stripe/services/entitlements/feature_service.rb +76 -0
- data/lib/stripe/services/ephemeral_key_service.rb +36 -0
- data/lib/stripe/services/event_service.rb +65 -0
- data/lib/stripe/services/exchange_rate_service.rb +27 -0
- data/lib/stripe/services/file_link_service.rb +94 -0
- data/lib/stripe/services/file_service.rb +89 -0
- data/lib/stripe/services/financial_connections/account_owner_service.rb +27 -0
- data/lib/stripe/services/financial_connections/account_service.rb +96 -0
- data/lib/stripe/services/financial_connections/session_service.rb +68 -0
- data/lib/stripe/services/financial_connections/transaction_service.rb +70 -0
- data/lib/stripe/services/forwarding/request_service.rb +106 -0
- data/lib/stripe/services/identity/verification_report_service.rb +65 -0
- data/lib/stripe/services/identity/verification_session_service.rb +231 -0
- data/lib/stripe/services/invoice_item_service.rb +334 -0
- data/lib/stripe/services/invoice_line_item_service.rb +221 -0
- data/lib/stripe/services/invoice_payment_service.rb +83 -0
- data/lib/stripe/services/invoice_rendering_template_service.rb +51 -0
- data/lib/stripe/services/invoice_service.rb +2648 -19
- data/lib/stripe/services/issuing/authorization_service.rb +104 -0
- data/lib/stripe/services/issuing/card_service.rb +455 -0
- data/lib/stripe/services/issuing/cardholder_service.rb +525 -0
- data/lib/stripe/services/issuing/dispute_service.rb +633 -0
- data/lib/stripe/services/issuing/personalization_design_service.rb +193 -0
- data/lib/stripe/services/issuing/physical_bundle_service.rb +40 -0
- data/lib/stripe/services/issuing/token_service.rb +73 -0
- data/lib/stripe/services/issuing/transaction_service.rb +77 -0
- data/lib/stripe/services/mandate_service.rb +9 -0
- data/lib/stripe/services/payment_intent_service.rb +7054 -0
- data/lib/stripe/services/payment_link_line_item_service.rb +18 -0
- data/lib/stripe/services/payment_link_service.rb +1276 -0
- data/lib/stripe/services/payment_method_configuration_service.rb +2004 -0
- data/lib/stripe/services/payment_method_domain_service.rb +79 -3
- data/lib/stripe/services/payment_method_service.rb +808 -0
- data/lib/stripe/services/payout_service.rb +159 -0
- data/lib/stripe/services/plan_service.rb +249 -0
- data/lib/stripe/services/price_service.rb +494 -1
- data/lib/stripe/services/product_feature_service.rb +42 -0
- data/lib/stripe/services/product_service.rb +425 -0
- data/lib/stripe/services/promotion_code_service.rb +178 -0
- data/lib/stripe/services/quote_computed_upfront_line_items_service.rb +18 -0
- data/lib/stripe/services/quote_line_item_service.rb +18 -0
- data/lib/stripe/services/quote_service.rb +611 -0
- data/lib/stripe/services/radar/early_fraud_warning_service.rb +61 -0
- data/lib/stripe/services/radar/value_list_item_service.rb +79 -0
- data/lib/stripe/services/radar/value_list_service.rb +103 -0
- data/lib/stripe/services/refund_service.rb +137 -0
- data/lib/stripe/services/reporting/report_run_service.rb +106 -0
- data/lib/stripe/services/reporting/report_type_service.rb +18 -0
- data/lib/stripe/services/review_service.rb +56 -0
- data/lib/stripe/services/setup_attempt_service.rb +51 -0
- data/lib/stripe/services/setup_intent_service.rb +3163 -0
- data/lib/stripe/services/shipping_rate_service.rb +200 -0
- data/lib/stripe/services/sigma/scheduled_query_run_service.rb +27 -0
- data/lib/stripe/services/source_service.rb +601 -0
- data/lib/stripe/services/source_transaction_service.rb +18 -0
- data/lib/stripe/services/subscription_item_service.rb +282 -5
- data/lib/stripe/services/subscription_schedule_service.rb +1062 -0
- data/lib/stripe/services/subscription_service.rb +1412 -0
- data/lib/stripe/services/tax/calculation_line_item_service.rb +18 -0
- data/lib/stripe/services/tax/calculation_service.rb +205 -0
- data/lib/stripe/services/tax/registration_service.rb +1564 -0
- data/lib/stripe/services/tax/settings_service.rb +74 -0
- data/lib/stripe/services/tax/transaction_line_item_service.rb +18 -0
- data/lib/stripe/services/tax/transaction_service.rb +111 -0
- data/lib/stripe/services/tax_code_service.rb +27 -0
- data/lib/stripe/services/tax_id_service.rb +79 -0
- data/lib/stripe/services/tax_rate_service.rb +155 -0
- data/lib/stripe/services/terminal/configuration_service.rb +997 -0
- data/lib/stripe/services/terminal/connection_token_service.rb +12 -0
- data/lib/stripe/services/terminal/location_service.rb +144 -0
- data/lib/stripe/services/terminal/reader_service.rb +266 -0
- data/lib/stripe/services/test_helpers/confirmation_token_service.rb +642 -0
- data/lib/stripe/services/test_helpers/customer_service.rb +18 -0
- data/lib/stripe/services/test_helpers/issuing/authorization_service.rb +745 -0
- data/lib/stripe/services/test_helpers/issuing/card_service.rb +45 -0
- data/lib/stripe/services/test_helpers/issuing/personalization_design_service.rb +41 -0
- data/lib/stripe/services/test_helpers/issuing/transaction_service.rb +632 -0
- data/lib/stripe/services/test_helpers/refund_service.rb +9 -0
- data/lib/stripe/services/test_helpers/terminal/reader_service.rb +44 -0
- data/lib/stripe/services/test_helpers/test_clock_service.rb +57 -0
- data/lib/stripe/services/test_helpers/treasury/inbound_transfer_service.rb +38 -0
- data/lib/stripe/services/test_helpers/treasury/outbound_payment_service.rb +87 -0
- data/lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb +87 -0
- data/lib/stripe/services/test_helpers/treasury/received_credit_service.rb +60 -0
- data/lib/stripe/services/test_helpers/treasury/received_debit_service.rb +60 -0
- data/lib/stripe/services/token_service.rb +1140 -0
- data/lib/stripe/services/topup_service.rb +142 -0
- data/lib/stripe/services/transfer_reversal_service.rb +66 -0
- data/lib/stripe/services/transfer_service.rb +119 -0
- data/lib/stripe/services/treasury/credit_reversal_service.rb +59 -0
- data/lib/stripe/services/treasury/debit_reversal_service.rb +63 -0
- data/lib/stripe/services/treasury/financial_account_features_service.rb +166 -0
- data/lib/stripe/services/treasury/financial_account_service.rb +485 -1
- data/lib/stripe/services/treasury/inbound_transfer_service.rb +88 -0
- data/lib/stripe/services/treasury/outbound_payment_service.rb +258 -0
- data/lib/stripe/services/treasury/outbound_transfer_service.rb +124 -0
- data/lib/stripe/services/treasury/received_credit_service.rb +52 -0
- data/lib/stripe/services/treasury/received_debit_service.rb +40 -0
- data/lib/stripe/services/treasury/transaction_entry_service.rb +87 -0
- data/lib/stripe/services/treasury/transaction_service.rb +95 -0
- data/lib/stripe/services/v1_services.rb +2 -1
- data/lib/stripe/services/v2/billing/meter_event_adjustment_service.rb +23 -0
- data/lib/stripe/services/v2/billing/meter_event_service.rb +25 -0
- data/lib/stripe/services/v2/billing/meter_event_session_service.rb +3 -0
- data/lib/stripe/services/v2/billing/meter_event_stream_service.rb +33 -0
- data/lib/stripe/services/v2/core/event_destination_service.rb +143 -0
- data/lib/stripe/services/v2/core/event_service.rb +15 -0
- data/lib/stripe/services/webhook_endpoint_service.rb +96 -0
- data/lib/stripe/services.rb +1 -3
- data/lib/stripe/stripe_client.rb +2 -1
- data/lib/stripe/stripe_object.rb +5 -0
- data/lib/stripe/version.rb +1 -1
- data/lib/stripe.rb +1 -0
- data/rbi/stripe/resources/account.rbi +4840 -0
- data/rbi/stripe/resources/account_link.rbi +74 -0
- data/rbi/stripe/resources/account_session.rbi +894 -0
- data/rbi/stripe/resources/apple_pay_domain.rbi +90 -0
- data/rbi/stripe/resources/application.rbi +20 -0
- data/rbi/stripe/resources/application_fee.rbi +118 -0
- data/rbi/stripe/resources/application_fee_refund.rbi +37 -0
- data/rbi/stripe/resources/apps/secret.rbi +195 -0
- data/rbi/stripe/resources/balance.rbi +180 -0
- data/rbi/stripe/resources/balance_transaction.rbi +144 -0
- data/rbi/stripe/resources/bank_account.rbi +127 -0
- data/rbi/stripe/resources/billing/alert.rbi +201 -0
- data/rbi/stripe/resources/billing/alert_triggered.rbi +28 -0
- data/rbi/stripe/resources/billing/credit_balance_summary.rbi +63 -0
- data/rbi/stripe/resources/billing/credit_balance_transaction.rbi +147 -0
- data/rbi/stripe/resources/billing/credit_grant.rbi +291 -0
- data/rbi/stripe/resources/billing/meter.rbi +226 -0
- data/rbi/stripe/resources/billing/meter_event.rbi +64 -0
- data/rbi/stripe/resources/billing/meter_event_adjustment.rbi +64 -0
- data/rbi/stripe/resources/billing/meter_event_summary.rbi +35 -0
- data/rbi/stripe/resources/billing_portal/configuration.rbi +645 -0
- data/rbi/stripe/resources/billing_portal/session.rbi +345 -0
- data/rbi/stripe/resources/capability.rbi +125 -0
- data/rbi/stripe/resources/card.rbi +125 -0
- data/rbi/stripe/resources/cash_balance.rbi +32 -0
- data/rbi/stripe/resources/charge.rbi +2054 -0
- data/rbi/stripe/resources/checkout/session.rbi +3951 -0
- data/rbi/stripe/resources/climate/order.rbi +245 -0
- data/rbi/stripe/resources/climate/product.rbi +75 -0
- data/rbi/stripe/resources/climate/supplier.rbi +72 -0
- data/rbi/stripe/resources/confirmation_token.rbi +1793 -0
- data/rbi/stripe/resources/connect_collection_transfer.rbi +26 -0
- data/rbi/stripe/resources/country_spec.rbi +85 -0
- data/rbi/stripe/resources/coupon.rbi +252 -0
- data/rbi/stripe/resources/credit_note.rbi +747 -0
- data/rbi/stripe/resources/credit_note_line_item.rbi +101 -0
- data/rbi/stripe/resources/customer.rbi +1009 -0
- data/rbi/stripe/resources/customer_balance_transaction.rbi +56 -0
- data/rbi/stripe/resources/customer_cash_balance_transaction.rbi +151 -0
- data/rbi/stripe/resources/customer_session.rbi +200 -0
- data/rbi/stripe/resources/discount.rbi +53 -0
- data/rbi/stripe/resources/dispute.rbi +761 -0
- data/rbi/stripe/resources/entitlements/active_entitlement.rbi +58 -0
- data/rbi/stripe/resources/entitlements/active_entitlement_summary.rbi +23 -0
- data/rbi/stripe/resources/entitlements/feature.rbi +117 -0
- data/rbi/stripe/resources/ephemeral_key.rbi +44 -0
- data/rbi/stripe/resources/event.rbi +146 -0
- data/rbi/stripe/resources/exchange_rate.rbi +66 -0
- data/rbi/stripe/resources/file.rbi +143 -0
- data/rbi/stripe/resources/file_link.rbi +141 -0
- data/rbi/stripe/resources/financial_connections/account.rbi +339 -0
- data/rbi/stripe/resources/financial_connections/account_owner.rbi +35 -0
- data/rbi/stripe/resources/financial_connections/account_ownership.rbi +23 -0
- data/rbi/stripe/resources/financial_connections/session.rbi +123 -0
- data/rbi/stripe/resources/financial_connections/transaction.rbi +124 -0
- data/rbi/stripe/resources/forwarding/request.rbi +216 -0
- data/rbi/stripe/resources/funding_instructions.rbi +437 -0
- data/rbi/stripe/resources/identity/verification_report.rbi +351 -0
- data/rbi/stripe/resources/identity/verification_session.rbi +517 -0
- data/rbi/stripe/resources/invoice.rbi +3733 -0
- data/rbi/stripe/resources/invoice_item.rbi +475 -0
- data/rbi/stripe/resources/invoice_line_item.rbi +432 -0
- data/rbi/stripe/resources/invoice_payment.rbi +114 -0
- data/rbi/stripe/resources/invoice_rendering_template.rbi +104 -0
- data/rbi/stripe/resources/issuing/authorization.rbi +1283 -0
- data/rbi/stripe/resources/issuing/card.rbi +741 -0
- data/rbi/stripe/resources/issuing/cardholder.rbi +744 -0
- data/rbi/stripe/resources/issuing/dispute.rbi +913 -0
- data/rbi/stripe/resources/issuing/personalization_design.rbi +338 -0
- data/rbi/stripe/resources/issuing/physical_bundle.rbi +79 -0
- data/rbi/stripe/resources/issuing/token.rbi +226 -0
- data/rbi/stripe/resources/issuing/transaction.rbi +1061 -0
- data/rbi/stripe/resources/line_item.rbi +72 -0
- data/rbi/stripe/resources/login_link.rbi +18 -0
- data/rbi/stripe/resources/mandate.rbi +187 -0
- data/rbi/stripe/resources/payment_intent.rbi +9731 -0
- data/rbi/stripe/resources/payment_link.rbi +1801 -0
- data/rbi/stripe/resources/payment_method.rbi +1822 -0
- data/rbi/stripe/resources/payment_method_configuration.rbi +3154 -0
- data/rbi/stripe/resources/payment_method_domain.rbi +212 -0
- data/rbi/stripe/resources/payout.rbi +300 -0
- data/rbi/stripe/resources/person.rbi +371 -0
- data/rbi/stripe/resources/plan.rbi +373 -0
- data/rbi/stripe/resources/price.rbi +694 -0
- data/rbi/stripe/resources/product.rbi +557 -0
- data/rbi/stripe/resources/product_feature.rbi +26 -0
- data/rbi/stripe/resources/promotion_code.rbi +261 -0
- data/rbi/stripe/resources/quote.rbi +1123 -0
- data/rbi/stripe/resources/radar/early_fraud_warning.rbi +98 -0
- data/rbi/stripe/resources/radar/value_list.rbi +170 -0
- data/rbi/stripe/resources/radar/value_list_item.rbi +131 -0
- data/rbi/stripe/resources/refund.rbi +516 -0
- data/rbi/stripe/resources/reporting/report_run.rbi +191 -0
- data/rbi/stripe/resources/reporting/report_type.rbi +57 -0
- data/rbi/stripe/resources/reserve_transaction.rbi +23 -0
- data/rbi/stripe/resources/reversal.rbi +51 -0
- data/rbi/stripe/resources/review.rbi +154 -0
- data/rbi/stripe/resources/setup_attempt.rbi +477 -0
- data/rbi/stripe/resources/setup_intent.rbi +3860 -0
- data/rbi/stripe/resources/shipping_rate.rbi +305 -0
- data/rbi/stripe/resources/sigma/scheduled_query_run.rbi +75 -0
- data/rbi/stripe/resources/source.rbi +1496 -0
- data/rbi/stripe/resources/source_mandate_notification.rbi +77 -0
- data/rbi/stripe/resources/source_transaction.rbi +127 -0
- data/rbi/stripe/resources/subscription.rbi +1964 -0
- data/rbi/stripe/resources/subscription_item.rbi +370 -0
- data/rbi/stripe/resources/subscription_schedule.rbi +1495 -0
- data/rbi/stripe/resources/tax/calculation.rbi +474 -0
- data/rbi/stripe/resources/tax/calculation_line_item.rbi +88 -0
- data/rbi/stripe/resources/tax/registration.rbi +2485 -0
- data/rbi/stripe/resources/tax/settings.rbi +141 -0
- data/rbi/stripe/resources/tax/transaction.rbi +351 -0
- data/rbi/stripe/resources/tax/transaction_line_item.rbi +54 -0
- data/rbi/stripe/resources/tax_code.rbi +44 -0
- data/rbi/stripe/resources/tax_deducted_at_source.rbi +23 -0
- data/rbi/stripe/resources/tax_id.rbi +167 -0
- data/rbi/stripe/resources/tax_rate.rbi +239 -0
- data/rbi/stripe/resources/terminal/configuration.rbi +1388 -0
- data/rbi/stripe/resources/terminal/connection_token.rbi +37 -0
- data/rbi/stripe/resources/terminal/location.rbi +224 -0
- data/rbi/stripe/resources/terminal/reader.rbi +587 -0
- data/rbi/stripe/resources/test_helpers/test_clock.rbi +134 -0
- data/rbi/stripe/resources/token.rbi +1217 -0
- data/rbi/stripe/resources/topup.rbi +222 -0
- data/rbi/stripe/resources/transfer.rbi +199 -0
- data/rbi/stripe/resources/treasury/credit_reversal.rbi +119 -0
- data/rbi/stripe/resources/treasury/debit_reversal.rbi +131 -0
- data/rbi/stripe/resources/treasury/financial_account.rbi +865 -0
- data/rbi/stripe/resources/treasury/financial_account_features.rbi +260 -0
- data/rbi/stripe/resources/treasury/inbound_transfer.rbi +295 -0
- data/rbi/stripe/resources/treasury/outbound_payment.rbi +592 -0
- data/rbi/stripe/resources/treasury/outbound_transfer.rbi +431 -0
- data/rbi/stripe/resources/treasury/received_credit.rbi +302 -0
- data/rbi/stripe/resources/treasury/received_debit.rbi +256 -0
- data/rbi/stripe/resources/treasury/transaction.rbi +215 -0
- data/rbi/stripe/resources/treasury/transaction_entry.rbi +192 -0
- data/rbi/stripe/resources/v2/amount.rbi +14 -0
- data/rbi/stripe/resources/v2/billing/meter_event.rbi +37 -0
- data/rbi/stripe/resources/v2/billing/meter_event_adjustment.rbi +41 -0
- data/rbi/stripe/resources/v2/billing/meter_event_session.rbi +31 -0
- data/rbi/stripe/resources/v2/event.rbi +48 -0
- data/rbi/stripe/resources/v2/event_destination.rbi +91 -0
- data/rbi/stripe/resources/webhook_endpoint.rbi +170 -0
- data/rbi/stripe/services/account_capability_service.rbi +51 -0
- data/rbi/stripe/services/account_external_account_service.rbi +306 -0
- data/rbi/stripe/services/account_link_service.rbi +58 -0
- data/rbi/stripe/services/account_login_link_service.rbi +22 -0
- data/rbi/stripe/services/account_person_service.rbi +923 -0
- data/rbi/stripe/services/account_service.rbi +4143 -0
- data/rbi/stripe/services/account_session_service.rbi +572 -0
- data/rbi/stripe/services/apple_pay_domain_service.rbi +78 -0
- data/rbi/stripe/services/application_fee_refund_service.rbi +93 -0
- data/rbi/stripe/services/application_fee_service.rbi +78 -0
- data/rbi/stripe/services/apps/secret_service.rbi +151 -0
- data/rbi/stripe/services/apps_service.rbi +9 -0
- data/rbi/stripe/services/balance_service.rbi +21 -0
- data/rbi/stripe/services/balance_transaction_service.rbi +93 -0
- data/rbi/stripe/services/billing/alert_service.rbi +152 -0
- data/rbi/stripe/services/billing/credit_balance_summary_service.rbi +68 -0
- data/rbi/stripe/services/billing/credit_balance_transaction_service.rbi +59 -0
- data/rbi/stripe/services/billing/credit_grant_service.rbi +211 -0
- data/rbi/stripe/services/billing/meter_event_adjustment_service.rbi +42 -0
- data/rbi/stripe/services/billing/meter_event_service.rbi +42 -0
- data/rbi/stripe/services/billing/meter_event_summary_service.rbi +54 -0
- data/rbi/stripe/services/billing/meter_service.rbi +163 -0
- data/rbi/stripe/services/billing_portal/configuration_service.rbi +511 -0
- data/rbi/stripe/services/billing_portal/session_service.rbi +204 -0
- data/rbi/stripe/services/billing_portal_service.rbi +10 -0
- data/rbi/stripe/services/billing_service.rbi +15 -0
- data/rbi/stripe/services/charge_service.rbi +448 -0
- data/rbi/stripe/services/checkout/session_line_item_service.rbi +33 -0
- data/rbi/stripe/services/checkout/session_service.rbi +2585 -0
- data/rbi/stripe/services/checkout_service.rbi +9 -0
- data/rbi/stripe/services/climate/order_service.rbi +142 -0
- data/rbi/stripe/services/climate/product_service.rbi +46 -0
- data/rbi/stripe/services/climate/supplier_service.rbi +46 -0
- data/rbi/stripe/services/climate_service.rbi +11 -0
- data/rbi/stripe/services/confirmation_token_service.rbi +20 -0
- data/rbi/stripe/services/country_spec_service.rbi +44 -0
- data/rbi/stripe/services/coupon_service.rbi +196 -0
- data/rbi/stripe/services/credit_note_line_item_service.rbi +31 -0
- data/rbi/stripe/services/credit_note_preview_lines_service.rbi +167 -0
- data/rbi/stripe/services/credit_note_service.rbi +416 -0
- data/rbi/stripe/services/customer_balance_transaction_service.rbi +92 -0
- data/rbi/stripe/services/customer_cash_balance_service.rbi +45 -0
- data/rbi/stripe/services/customer_cash_balance_transaction_service.rbi +44 -0
- data/rbi/stripe/services/customer_funding_instructions_service.rbi +59 -0
- data/rbi/stripe/services/customer_payment_method_service.rbi +57 -0
- data/rbi/stripe/services/customer_payment_source_service.rbi +232 -0
- data/rbi/stripe/services/customer_service.rbi +651 -0
- data/rbi/stripe/services/customer_session_service.rbi +116 -0
- data/rbi/stripe/services/customer_tax_id_service.rbi +72 -0
- data/rbi/stripe/services/dispute_service.rbi +424 -0
- data/rbi/stripe/services/entitlements/active_entitlement_service.rbi +55 -0
- data/rbi/stripe/services/entitlements/feature_service.rbi +107 -0
- data/rbi/stripe/services/entitlements_service.rbi +10 -0
- data/rbi/stripe/services/ephemeral_key_service.rbi +53 -0
- data/rbi/stripe/services/event_service.rbi +83 -0
- data/rbi/stripe/services/exchange_rate_service.rbi +44 -0
- data/rbi/stripe/services/file_link_service.rbi +124 -0
- data/rbi/stripe/services/file_service.rbi +116 -0
- data/rbi/stripe/services/financial_connections/account_owner_service.rbi +42 -0
- data/rbi/stripe/services/financial_connections/account_service.rbi +133 -0
- data/rbi/stripe/services/financial_connections/session_service.rbi +88 -0
- data/rbi/stripe/services/financial_connections/transaction_service.rbi +92 -0
- data/rbi/stripe/services/financial_connections_service.rbi +11 -0
- data/rbi/stripe/services/forwarding/request_service.rbi +134 -0
- data/rbi/stripe/services/forwarding_service.rbi +9 -0
- data/rbi/stripe/services/identity/verification_report_service.rbi +87 -0
- data/rbi/stripe/services/identity/verification_session_service.rbi +323 -0
- data/rbi/stripe/services/identity_service.rbi +10 -0
- data/rbi/stripe/services/invoice_item_service.rbi +368 -0
- data/rbi/stripe/services/invoice_line_item_service.rbi +259 -0
- data/rbi/stripe/services/invoice_payment_service.rbi +71 -0
- data/rbi/stripe/services/invoice_rendering_template_service.rbi +82 -0
- data/rbi/stripe/services/invoice_service.rbi +2920 -0
- data/rbi/stripe/services/issuing/authorization_service.rbi +146 -0
- data/rbi/stripe/services/issuing/card_service.rbi +495 -0
- data/rbi/stripe/services/issuing/cardholder_service.rbi +587 -0
- data/rbi/stripe/services/issuing/dispute_service.rbi +707 -0
- data/rbi/stripe/services/issuing/personalization_design_service.rbi +243 -0
- data/rbi/stripe/services/issuing/physical_bundle_service.rbi +59 -0
- data/rbi/stripe/services/issuing/token_service.rbi +99 -0
- data/rbi/stripe/services/issuing/transaction_service.rbi +105 -0
- data/rbi/stripe/services/issuing_service.rbi +16 -0
- data/rbi/stripe/services/mandate_service.rbi +20 -0
- data/rbi/stripe/services/payment_intent_service.rbi +7759 -0
- data/rbi/stripe/services/payment_link_line_item_service.rbi +31 -0
- data/rbi/stripe/services/payment_link_service.rbi +1352 -0
- data/rbi/stripe/services/payment_method_configuration_service.rbi +2211 -0
- data/rbi/stripe/services/payment_method_domain_service.rbi +112 -0
- data/rbi/stripe/services/payment_method_service.rbi +840 -0
- data/rbi/stripe/services/payout_service.rbi +205 -0
- data/rbi/stripe/services/plan_service.rbi +284 -0
- data/rbi/stripe/services/price_service.rbi +546 -0
- data/rbi/stripe/services/product_feature_service.rbi +69 -0
- data/rbi/stripe/services/product_service.rbi +479 -0
- data/rbi/stripe/services/promotion_code_service.rbi +214 -0
- data/rbi/stripe/services/quote_computed_upfront_line_items_service.rbi +31 -0
- data/rbi/stripe/services/quote_line_item_service.rbi +31 -0
- data/rbi/stripe/services/quote_service.rbi +686 -0
- data/rbi/stripe/services/radar/early_fraud_warning_service.rbi +85 -0
- data/rbi/stripe/services/radar/value_list_item_service.rbi +111 -0
- data/rbi/stripe/services/radar/value_list_service.rbi +143 -0
- data/rbi/stripe/services/radar_service.rbi +11 -0
- data/rbi/stripe/services/refund_service.rbi +185 -0
- data/rbi/stripe/services/reporting/report_run_service.rbi +135 -0
- data/rbi/stripe/services/reporting/report_type_service.rbi +35 -0
- data/rbi/stripe/services/reporting_service.rbi +10 -0
- data/rbi/stripe/services/review_service.rbi +84 -0
- data/rbi/stripe/services/setup_attempt_service.rbi +65 -0
- data/rbi/stripe/services/setup_intent_service.rbi +3596 -0
- data/rbi/stripe/services/shipping_rate_service.rbi +241 -0
- data/rbi/stripe/services/sigma/scheduled_query_run_service.rbi +46 -0
- data/rbi/stripe/services/sigma_service.rbi +9 -0
- data/rbi/stripe/services/source_service.rbi +663 -0
- data/rbi/stripe/services/source_transaction_service.rbi +31 -0
- data/rbi/stripe/services/subscription_item_service.rbi +324 -0
- data/rbi/stripe/services/subscription_schedule_service.rbi +1192 -0
- data/rbi/stripe/services/subscription_service.rbi +1596 -0
- data/rbi/stripe/services/tax/calculation_line_item_service.rbi +33 -0
- data/rbi/stripe/services/tax/calculation_service.rbi +230 -0
- data/rbi/stripe/services/tax/registration_service.rbi +1689 -0
- data/rbi/stripe/services/tax/settings_service.rbi +93 -0
- data/rbi/stripe/services/tax/transaction_line_item_service.rbi +33 -0
- data/rbi/stripe/services/tax/transaction_service.rbi +146 -0
- data/rbi/stripe/services/tax_code_service.rbi +44 -0
- data/rbi/stripe/services/tax_id_service.rbi +112 -0
- data/rbi/stripe/services/tax_rate_service.rbi +185 -0
- data/rbi/stripe/services/tax_service.rbi +12 -0
- data/rbi/stripe/services/terminal/configuration_service.rbi +1120 -0
- data/rbi/stripe/services/terminal/connection_token_service.rbi +25 -0
- data/rbi/stripe/services/terminal/location_service.rbi +184 -0
- data/rbi/stripe/services/terminal/reader_service.rbi +344 -0
- data/rbi/stripe/services/terminal_service.rbi +12 -0
- data/rbi/stripe/services/test_helpers/confirmation_token_service.rbi +746 -0
- data/rbi/stripe/services/test_helpers/customer_service.rbi +33 -0
- data/rbi/stripe/services/test_helpers/issuing/authorization_service.rbi +848 -0
- data/rbi/stripe/services/test_helpers/issuing/card_service.rbi +76 -0
- data/rbi/stripe/services/test_helpers/issuing/personalization_design_service.rbi +69 -0
- data/rbi/stripe/services/test_helpers/issuing/transaction_service.rbi +711 -0
- data/rbi/stripe/services/test_helpers/issuing_service.rbi +14 -0
- data/rbi/stripe/services/test_helpers/refund_service.rbi +22 -0
- data/rbi/stripe/services/test_helpers/terminal/reader_service.rbi +62 -0
- data/rbi/stripe/services/test_helpers/terminal_service.rbi +11 -0
- data/rbi/stripe/services/test_helpers/test_clock_service.rbi +92 -0
- data/rbi/stripe/services/test_helpers/treasury/inbound_transfer_service.rbi +64 -0
- data/rbi/stripe/services/test_helpers/treasury/outbound_payment_service.rbi +125 -0
- data/rbi/stripe/services/test_helpers/treasury/outbound_transfer_service.rbi +125 -0
- data/rbi/stripe/services/test_helpers/treasury/received_credit_service.rbi +87 -0
- data/rbi/stripe/services/test_helpers/treasury/received_debit_service.rbi +87 -0
- data/rbi/stripe/services/test_helpers/treasury_service.rbi +15 -0
- data/rbi/stripe/services/test_helpers_service.rbi +15 -0
- data/rbi/stripe/services/token_service.rbi +1189 -0
- data/rbi/stripe/services/topup_service.rbi +176 -0
- data/rbi/stripe/services/transfer_reversal_service.rbi +101 -0
- data/rbi/stripe/services/transfer_service.rbi +152 -0
- data/rbi/stripe/services/treasury/credit_reversal_service.rbi +84 -0
- data/rbi/stripe/services/treasury/debit_reversal_service.rbi +88 -0
- data/rbi/stripe/services/treasury/financial_account_features_service.rbi +198 -0
- data/rbi/stripe/services/treasury/financial_account_service.rbi +562 -0
- data/rbi/stripe/services/treasury/inbound_transfer_service.rbi +117 -0
- data/rbi/stripe/services/treasury/outbound_payment_service.rbi +304 -0
- data/rbi/stripe/services/treasury/outbound_transfer_service.rbi +157 -0
- data/rbi/stripe/services/treasury/received_credit_service.rbi +72 -0
- data/rbi/stripe/services/treasury/received_debit_service.rbi +59 -0
- data/rbi/stripe/services/treasury/transaction_entry_service.rbi +111 -0
- data/rbi/stripe/services/treasury/transaction_service.rbi +122 -0
- data/rbi/stripe/services/treasury_service.rbi +18 -0
- data/rbi/stripe/services/v1_services.rbi +77 -0
- data/rbi/stripe/services/v2/billing/meter_event_adjustment_service.rbi +39 -0
- data/rbi/stripe/services/v2/billing/meter_event_service.rbi +42 -0
- data/rbi/stripe/services/v2/billing/meter_event_session_service.rbi +20 -0
- data/rbi/stripe/services/v2/billing/meter_event_stream_service.rbi +55 -0
- data/rbi/stripe/services/v2/billing_service.rbi +14 -0
- data/rbi/stripe/services/v2/core/event_destination_service.rbi +200 -0
- data/rbi/stripe/services/v2/core/event_service.rbi +36 -0
- data/rbi/stripe/services/v2/core_service.rbi +12 -0
- data/rbi/stripe/services/v2_services.rbi +10 -0
- data/rbi/stripe/services/webhook_endpoint_service.rbi +131 -0
- metadata +333 -7
- data/lib/stripe/resources/usage_record.rb +0 -17
- data/lib/stripe/resources/usage_record_summary.rb +0 -12
- data/lib/stripe/services/invoice_upcoming_lines_service.rb +0 -17
- data/lib/stripe/services/subscription_item_usage_record_service.rb +0 -23
- data/lib/stripe/services/subscription_item_usage_record_summary_service.rb +0 -19
@@ -4,6 +4,179 @@
|
|
4
4
|
module Stripe
|
5
5
|
module BillingPortal
|
6
6
|
class SessionService < StripeService
|
7
|
+
class CreateParams < Stripe::RequestParams
|
8
|
+
class FlowData < Stripe::RequestParams
|
9
|
+
class AfterCompletion < Stripe::RequestParams
|
10
|
+
class HostedConfirmation < Stripe::RequestParams
|
11
|
+
# A custom message to display to the customer after the flow is completed.
|
12
|
+
attr_accessor :custom_message
|
13
|
+
|
14
|
+
def initialize(custom_message: nil)
|
15
|
+
@custom_message = custom_message
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
class Redirect < Stripe::RequestParams
|
20
|
+
# The URL the customer will be redirected to after the flow is completed.
|
21
|
+
attr_accessor :return_url
|
22
|
+
|
23
|
+
def initialize(return_url: nil)
|
24
|
+
@return_url = return_url
|
25
|
+
end
|
26
|
+
end
|
27
|
+
# Configuration when `after_completion.type=hosted_confirmation`.
|
28
|
+
attr_accessor :hosted_confirmation
|
29
|
+
# Configuration when `after_completion.type=redirect`.
|
30
|
+
attr_accessor :redirect
|
31
|
+
# The specified behavior after the flow is completed.
|
32
|
+
attr_accessor :type
|
33
|
+
|
34
|
+
def initialize(hosted_confirmation: nil, redirect: nil, type: nil)
|
35
|
+
@hosted_confirmation = hosted_confirmation
|
36
|
+
@redirect = redirect
|
37
|
+
@type = type
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
class SubscriptionCancel < Stripe::RequestParams
|
42
|
+
class Retention < Stripe::RequestParams
|
43
|
+
class CouponOffer < Stripe::RequestParams
|
44
|
+
# The ID of the coupon to be offered.
|
45
|
+
attr_accessor :coupon
|
46
|
+
|
47
|
+
def initialize(coupon: nil)
|
48
|
+
@coupon = coupon
|
49
|
+
end
|
50
|
+
end
|
51
|
+
# Configuration when `retention.type=coupon_offer`.
|
52
|
+
attr_accessor :coupon_offer
|
53
|
+
# Type of retention strategy to use with the customer.
|
54
|
+
attr_accessor :type
|
55
|
+
|
56
|
+
def initialize(coupon_offer: nil, type: nil)
|
57
|
+
@coupon_offer = coupon_offer
|
58
|
+
@type = type
|
59
|
+
end
|
60
|
+
end
|
61
|
+
# Specify a retention strategy to be used in the cancellation flow.
|
62
|
+
attr_accessor :retention
|
63
|
+
# The ID of the subscription to be canceled.
|
64
|
+
attr_accessor :subscription
|
65
|
+
|
66
|
+
def initialize(retention: nil, subscription: nil)
|
67
|
+
@retention = retention
|
68
|
+
@subscription = subscription
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
class SubscriptionUpdate < Stripe::RequestParams
|
73
|
+
# The ID of the subscription to be updated.
|
74
|
+
attr_accessor :subscription
|
75
|
+
|
76
|
+
def initialize(subscription: nil)
|
77
|
+
@subscription = subscription
|
78
|
+
end
|
79
|
+
end
|
80
|
+
|
81
|
+
class SubscriptionUpdateConfirm < Stripe::RequestParams
|
82
|
+
class Discount < Stripe::RequestParams
|
83
|
+
# The ID of the coupon to apply to this subscription update.
|
84
|
+
attr_accessor :coupon
|
85
|
+
# The ID of a promotion code to apply to this subscription update.
|
86
|
+
attr_accessor :promotion_code
|
87
|
+
|
88
|
+
def initialize(coupon: nil, promotion_code: nil)
|
89
|
+
@coupon = coupon
|
90
|
+
@promotion_code = promotion_code
|
91
|
+
end
|
92
|
+
end
|
93
|
+
|
94
|
+
class Item < Stripe::RequestParams
|
95
|
+
# The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.
|
96
|
+
attr_accessor :id
|
97
|
+
# The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).
|
98
|
+
attr_accessor :price
|
99
|
+
# [Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.
|
100
|
+
attr_accessor :quantity
|
101
|
+
|
102
|
+
def initialize(id: nil, price: nil, quantity: nil)
|
103
|
+
@id = id
|
104
|
+
@price = price
|
105
|
+
@quantity = quantity
|
106
|
+
end
|
107
|
+
end
|
108
|
+
# The coupon or promotion code to apply to this subscription update. Currently, only up to one may be specified.
|
109
|
+
attr_accessor :discounts
|
110
|
+
# The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.
|
111
|
+
attr_accessor :items
|
112
|
+
# The ID of the subscription to be updated.
|
113
|
+
attr_accessor :subscription
|
114
|
+
|
115
|
+
def initialize(discounts: nil, items: nil, subscription: nil)
|
116
|
+
@discounts = discounts
|
117
|
+
@items = items
|
118
|
+
@subscription = subscription
|
119
|
+
end
|
120
|
+
end
|
121
|
+
# Behavior after the flow is completed.
|
122
|
+
attr_accessor :after_completion
|
123
|
+
# Configuration when `flow_data.type=subscription_cancel`.
|
124
|
+
attr_accessor :subscription_cancel
|
125
|
+
# Configuration when `flow_data.type=subscription_update`.
|
126
|
+
attr_accessor :subscription_update
|
127
|
+
# Configuration when `flow_data.type=subscription_update_confirm`.
|
128
|
+
attr_accessor :subscription_update_confirm
|
129
|
+
# Type of flow that the customer will go through.
|
130
|
+
attr_accessor :type
|
131
|
+
|
132
|
+
def initialize(
|
133
|
+
after_completion: nil,
|
134
|
+
subscription_cancel: nil,
|
135
|
+
subscription_update: nil,
|
136
|
+
subscription_update_confirm: nil,
|
137
|
+
type: nil
|
138
|
+
)
|
139
|
+
@after_completion = after_completion
|
140
|
+
@subscription_cancel = subscription_cancel
|
141
|
+
@subscription_update = subscription_update
|
142
|
+
@subscription_update_confirm = subscription_update_confirm
|
143
|
+
@type = type
|
144
|
+
end
|
145
|
+
end
|
146
|
+
# The ID of an existing [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.
|
147
|
+
attr_accessor :configuration
|
148
|
+
# The ID of an existing customer.
|
149
|
+
attr_accessor :customer
|
150
|
+
# Specifies which fields in the response should be expanded.
|
151
|
+
attr_accessor :expand
|
152
|
+
# Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.
|
153
|
+
attr_accessor :flow_data
|
154
|
+
# The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer’s `preferred_locales` or browser’s locale is used.
|
155
|
+
attr_accessor :locale
|
156
|
+
# The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
|
157
|
+
attr_accessor :on_behalf_of
|
158
|
+
# The default URL to redirect customers to when they click on the portal's link to return to your website.
|
159
|
+
attr_accessor :return_url
|
160
|
+
|
161
|
+
def initialize(
|
162
|
+
configuration: nil,
|
163
|
+
customer: nil,
|
164
|
+
expand: nil,
|
165
|
+
flow_data: nil,
|
166
|
+
locale: nil,
|
167
|
+
on_behalf_of: nil,
|
168
|
+
return_url: nil
|
169
|
+
)
|
170
|
+
@configuration = configuration
|
171
|
+
@customer = customer
|
172
|
+
@expand = expand
|
173
|
+
@flow_data = flow_data
|
174
|
+
@locale = locale
|
175
|
+
@on_behalf_of = on_behalf_of
|
176
|
+
@return_url = return_url
|
177
|
+
end
|
178
|
+
end
|
179
|
+
|
7
180
|
# Creates a session of the customer portal.
|
8
181
|
def create(params = {}, opts = {})
|
9
182
|
request(
|
@@ -3,6 +3,408 @@
|
|
3
3
|
|
4
4
|
module Stripe
|
5
5
|
class ChargeService < StripeService
|
6
|
+
class ListParams < Stripe::RequestParams
|
7
|
+
class Created < Stripe::RequestParams
|
8
|
+
# Minimum value to filter by (exclusive)
|
9
|
+
attr_accessor :gt
|
10
|
+
# Minimum value to filter by (inclusive)
|
11
|
+
attr_accessor :gte
|
12
|
+
# Maximum value to filter by (exclusive)
|
13
|
+
attr_accessor :lt
|
14
|
+
# Maximum value to filter by (inclusive)
|
15
|
+
attr_accessor :lte
|
16
|
+
|
17
|
+
def initialize(gt: nil, gte: nil, lt: nil, lte: nil)
|
18
|
+
@gt = gt
|
19
|
+
@gte = gte
|
20
|
+
@lt = lt
|
21
|
+
@lte = lte
|
22
|
+
end
|
23
|
+
end
|
24
|
+
# Only return charges that were created during the given date interval.
|
25
|
+
attr_accessor :created
|
26
|
+
# Only return charges for the customer specified by this customer ID.
|
27
|
+
attr_accessor :customer
|
28
|
+
# 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.
|
29
|
+
attr_accessor :ending_before
|
30
|
+
# Specifies which fields in the response should be expanded.
|
31
|
+
attr_accessor :expand
|
32
|
+
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
33
|
+
attr_accessor :limit
|
34
|
+
# Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.
|
35
|
+
attr_accessor :payment_intent
|
36
|
+
# 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.
|
37
|
+
attr_accessor :starting_after
|
38
|
+
# Only return charges for this transfer group, limited to 100.
|
39
|
+
attr_accessor :transfer_group
|
40
|
+
|
41
|
+
def initialize(
|
42
|
+
created: nil,
|
43
|
+
customer: nil,
|
44
|
+
ending_before: nil,
|
45
|
+
expand: nil,
|
46
|
+
limit: nil,
|
47
|
+
payment_intent: nil,
|
48
|
+
starting_after: nil,
|
49
|
+
transfer_group: nil
|
50
|
+
)
|
51
|
+
@created = created
|
52
|
+
@customer = customer
|
53
|
+
@ending_before = ending_before
|
54
|
+
@expand = expand
|
55
|
+
@limit = limit
|
56
|
+
@payment_intent = payment_intent
|
57
|
+
@starting_after = starting_after
|
58
|
+
@transfer_group = transfer_group
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
class CreateParams < Stripe::RequestParams
|
63
|
+
class Destination < Stripe::RequestParams
|
64
|
+
# ID of an existing, connected Stripe account.
|
65
|
+
attr_accessor :account
|
66
|
+
# The amount to transfer to the destination account without creating an `Application Fee` object. Cannot be combined with the `application_fee` parameter. Must be less than or equal to the charge amount.
|
67
|
+
attr_accessor :amount
|
68
|
+
|
69
|
+
def initialize(account: nil, amount: nil)
|
70
|
+
@account = account
|
71
|
+
@amount = amount
|
72
|
+
end
|
73
|
+
end
|
74
|
+
|
75
|
+
class RadarOptions < Stripe::RequestParams
|
76
|
+
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
|
77
|
+
attr_accessor :session
|
78
|
+
|
79
|
+
def initialize(session: nil)
|
80
|
+
@session = session
|
81
|
+
end
|
82
|
+
end
|
83
|
+
|
84
|
+
class Shipping < Stripe::RequestParams
|
85
|
+
class Address < Stripe::RequestParams
|
86
|
+
# City, district, suburb, town, or village.
|
87
|
+
attr_accessor :city
|
88
|
+
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
|
89
|
+
attr_accessor :country
|
90
|
+
# Address line 1 (e.g., street, PO Box, or company name).
|
91
|
+
attr_accessor :line1
|
92
|
+
# Address line 2 (e.g., apartment, suite, unit, or building).
|
93
|
+
attr_accessor :line2
|
94
|
+
# ZIP or postal code.
|
95
|
+
attr_accessor :postal_code
|
96
|
+
# State, county, province, or region.
|
97
|
+
attr_accessor :state
|
98
|
+
|
99
|
+
def initialize(
|
100
|
+
city: nil,
|
101
|
+
country: nil,
|
102
|
+
line1: nil,
|
103
|
+
line2: nil,
|
104
|
+
postal_code: nil,
|
105
|
+
state: nil
|
106
|
+
)
|
107
|
+
@city = city
|
108
|
+
@country = country
|
109
|
+
@line1 = line1
|
110
|
+
@line2 = line2
|
111
|
+
@postal_code = postal_code
|
112
|
+
@state = state
|
113
|
+
end
|
114
|
+
end
|
115
|
+
# Shipping address.
|
116
|
+
attr_accessor :address
|
117
|
+
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
|
118
|
+
attr_accessor :carrier
|
119
|
+
# Recipient name.
|
120
|
+
attr_accessor :name
|
121
|
+
# Recipient phone (including extension).
|
122
|
+
attr_accessor :phone
|
123
|
+
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
|
124
|
+
attr_accessor :tracking_number
|
125
|
+
|
126
|
+
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil)
|
127
|
+
@address = address
|
128
|
+
@carrier = carrier
|
129
|
+
@name = name
|
130
|
+
@phone = phone
|
131
|
+
@tracking_number = tracking_number
|
132
|
+
end
|
133
|
+
end
|
134
|
+
|
135
|
+
class TransferData < Stripe::RequestParams
|
136
|
+
# The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
|
137
|
+
attr_accessor :amount
|
138
|
+
# ID of an existing, connected Stripe account.
|
139
|
+
attr_accessor :destination
|
140
|
+
|
141
|
+
def initialize(amount: nil, destination: nil)
|
142
|
+
@amount = amount
|
143
|
+
@destination = destination
|
144
|
+
end
|
145
|
+
end
|
146
|
+
# Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
|
147
|
+
attr_accessor :amount
|
148
|
+
# Attribute for param field application_fee
|
149
|
+
attr_accessor :application_fee
|
150
|
+
# A fee in cents (or local equivalent) that will be applied to the charge and transferred to the application owner's Stripe account. The request must be made with an OAuth key or the `Stripe-Account` header in order to take an application fee. For more information, see the application fees [documentation](https://stripe.com/docs/connect/direct-charges#collect-fees).
|
151
|
+
attr_accessor :application_fee_amount
|
152
|
+
# Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire after a set number of days (7 by default). For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.
|
153
|
+
attr_accessor :capture
|
154
|
+
# 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).
|
155
|
+
attr_accessor :currency
|
156
|
+
# The ID of an existing customer that will be charged in this request.
|
157
|
+
attr_accessor :customer
|
158
|
+
# An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
|
159
|
+
attr_accessor :description
|
160
|
+
# Attribute for param field destination
|
161
|
+
attr_accessor :destination
|
162
|
+
# Specifies which fields in the response should be expanded.
|
163
|
+
attr_accessor :expand
|
164
|
+
# 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. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
|
165
|
+
attr_accessor :metadata
|
166
|
+
# The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).
|
167
|
+
attr_accessor :on_behalf_of
|
168
|
+
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
|
169
|
+
attr_accessor :radar_options
|
170
|
+
# The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
|
171
|
+
attr_accessor :receipt_email
|
172
|
+
# Shipping information for the charge. Helps prevent fraud on charges for physical goods.
|
173
|
+
attr_accessor :shipping
|
174
|
+
# A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.
|
175
|
+
attr_accessor :source
|
176
|
+
# For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
|
177
|
+
#
|
178
|
+
# For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
|
179
|
+
attr_accessor :statement_descriptor
|
180
|
+
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
|
181
|
+
attr_accessor :statement_descriptor_suffix
|
182
|
+
# An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
|
183
|
+
attr_accessor :transfer_data
|
184
|
+
# A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options).
|
185
|
+
attr_accessor :transfer_group
|
186
|
+
|
187
|
+
def initialize(
|
188
|
+
amount: nil,
|
189
|
+
application_fee: nil,
|
190
|
+
application_fee_amount: nil,
|
191
|
+
capture: nil,
|
192
|
+
currency: nil,
|
193
|
+
customer: nil,
|
194
|
+
description: nil,
|
195
|
+
destination: nil,
|
196
|
+
expand: nil,
|
197
|
+
metadata: nil,
|
198
|
+
on_behalf_of: nil,
|
199
|
+
radar_options: nil,
|
200
|
+
receipt_email: nil,
|
201
|
+
shipping: nil,
|
202
|
+
source: nil,
|
203
|
+
statement_descriptor: nil,
|
204
|
+
statement_descriptor_suffix: nil,
|
205
|
+
transfer_data: nil,
|
206
|
+
transfer_group: nil
|
207
|
+
)
|
208
|
+
@amount = amount
|
209
|
+
@application_fee = application_fee
|
210
|
+
@application_fee_amount = application_fee_amount
|
211
|
+
@capture = capture
|
212
|
+
@currency = currency
|
213
|
+
@customer = customer
|
214
|
+
@description = description
|
215
|
+
@destination = destination
|
216
|
+
@expand = expand
|
217
|
+
@metadata = metadata
|
218
|
+
@on_behalf_of = on_behalf_of
|
219
|
+
@radar_options = radar_options
|
220
|
+
@receipt_email = receipt_email
|
221
|
+
@shipping = shipping
|
222
|
+
@source = source
|
223
|
+
@statement_descriptor = statement_descriptor
|
224
|
+
@statement_descriptor_suffix = statement_descriptor_suffix
|
225
|
+
@transfer_data = transfer_data
|
226
|
+
@transfer_group = transfer_group
|
227
|
+
end
|
228
|
+
end
|
229
|
+
|
230
|
+
class RetrieveParams < Stripe::RequestParams
|
231
|
+
# Specifies which fields in the response should be expanded.
|
232
|
+
attr_accessor :expand
|
233
|
+
|
234
|
+
def initialize(expand: nil)
|
235
|
+
@expand = expand
|
236
|
+
end
|
237
|
+
end
|
238
|
+
|
239
|
+
class UpdateParams < Stripe::RequestParams
|
240
|
+
class FraudDetails < Stripe::RequestParams
|
241
|
+
# Either `safe` or `fraudulent`.
|
242
|
+
attr_accessor :user_report
|
243
|
+
|
244
|
+
def initialize(user_report: nil)
|
245
|
+
@user_report = user_report
|
246
|
+
end
|
247
|
+
end
|
248
|
+
|
249
|
+
class Shipping < Stripe::RequestParams
|
250
|
+
class Address < Stripe::RequestParams
|
251
|
+
# City, district, suburb, town, or village.
|
252
|
+
attr_accessor :city
|
253
|
+
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
|
254
|
+
attr_accessor :country
|
255
|
+
# Address line 1 (e.g., street, PO Box, or company name).
|
256
|
+
attr_accessor :line1
|
257
|
+
# Address line 2 (e.g., apartment, suite, unit, or building).
|
258
|
+
attr_accessor :line2
|
259
|
+
# ZIP or postal code.
|
260
|
+
attr_accessor :postal_code
|
261
|
+
# State, county, province, or region.
|
262
|
+
attr_accessor :state
|
263
|
+
|
264
|
+
def initialize(
|
265
|
+
city: nil,
|
266
|
+
country: nil,
|
267
|
+
line1: nil,
|
268
|
+
line2: nil,
|
269
|
+
postal_code: nil,
|
270
|
+
state: nil
|
271
|
+
)
|
272
|
+
@city = city
|
273
|
+
@country = country
|
274
|
+
@line1 = line1
|
275
|
+
@line2 = line2
|
276
|
+
@postal_code = postal_code
|
277
|
+
@state = state
|
278
|
+
end
|
279
|
+
end
|
280
|
+
# Shipping address.
|
281
|
+
attr_accessor :address
|
282
|
+
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
|
283
|
+
attr_accessor :carrier
|
284
|
+
# Recipient name.
|
285
|
+
attr_accessor :name
|
286
|
+
# Recipient phone (including extension).
|
287
|
+
attr_accessor :phone
|
288
|
+
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
|
289
|
+
attr_accessor :tracking_number
|
290
|
+
|
291
|
+
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil)
|
292
|
+
@address = address
|
293
|
+
@carrier = carrier
|
294
|
+
@name = name
|
295
|
+
@phone = phone
|
296
|
+
@tracking_number = tracking_number
|
297
|
+
end
|
298
|
+
end
|
299
|
+
# The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.
|
300
|
+
attr_accessor :customer
|
301
|
+
# An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
|
302
|
+
attr_accessor :description
|
303
|
+
# Specifies which fields in the response should be expanded.
|
304
|
+
attr_accessor :expand
|
305
|
+
# A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.
|
306
|
+
attr_accessor :fraud_details
|
307
|
+
# 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. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
|
308
|
+
attr_accessor :metadata
|
309
|
+
# This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.
|
310
|
+
attr_accessor :receipt_email
|
311
|
+
# Shipping information for the charge. Helps prevent fraud on charges for physical goods.
|
312
|
+
attr_accessor :shipping
|
313
|
+
# A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
|
314
|
+
attr_accessor :transfer_group
|
315
|
+
|
316
|
+
def initialize(
|
317
|
+
customer: nil,
|
318
|
+
description: nil,
|
319
|
+
expand: nil,
|
320
|
+
fraud_details: nil,
|
321
|
+
metadata: nil,
|
322
|
+
receipt_email: nil,
|
323
|
+
shipping: nil,
|
324
|
+
transfer_group: nil
|
325
|
+
)
|
326
|
+
@customer = customer
|
327
|
+
@description = description
|
328
|
+
@expand = expand
|
329
|
+
@fraud_details = fraud_details
|
330
|
+
@metadata = metadata
|
331
|
+
@receipt_email = receipt_email
|
332
|
+
@shipping = shipping
|
333
|
+
@transfer_group = transfer_group
|
334
|
+
end
|
335
|
+
end
|
336
|
+
|
337
|
+
class SearchParams < Stripe::RequestParams
|
338
|
+
# Specifies which fields in the response should be expanded.
|
339
|
+
attr_accessor :expand
|
340
|
+
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
341
|
+
attr_accessor :limit
|
342
|
+
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
|
343
|
+
attr_accessor :page
|
344
|
+
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for charges](https://stripe.com/docs/search#query-fields-for-charges).
|
345
|
+
attr_accessor :query
|
346
|
+
|
347
|
+
def initialize(expand: nil, limit: nil, page: nil, query: nil)
|
348
|
+
@expand = expand
|
349
|
+
@limit = limit
|
350
|
+
@page = page
|
351
|
+
@query = query
|
352
|
+
end
|
353
|
+
end
|
354
|
+
|
355
|
+
class CaptureParams < Stripe::RequestParams
|
356
|
+
class TransferData < Stripe::RequestParams
|
357
|
+
# The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
|
358
|
+
attr_accessor :amount
|
359
|
+
|
360
|
+
def initialize(amount: nil)
|
361
|
+
@amount = amount
|
362
|
+
end
|
363
|
+
end
|
364
|
+
# The amount to capture, which must be less than or equal to the original amount.
|
365
|
+
attr_accessor :amount
|
366
|
+
# An application fee to add on to this charge.
|
367
|
+
attr_accessor :application_fee
|
368
|
+
# An application fee amount to add on to this charge, which must be less than or equal to the original amount.
|
369
|
+
attr_accessor :application_fee_amount
|
370
|
+
# Specifies which fields in the response should be expanded.
|
371
|
+
attr_accessor :expand
|
372
|
+
# The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.
|
373
|
+
attr_accessor :receipt_email
|
374
|
+
# For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
|
375
|
+
#
|
376
|
+
# For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
|
377
|
+
attr_accessor :statement_descriptor
|
378
|
+
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
|
379
|
+
attr_accessor :statement_descriptor_suffix
|
380
|
+
# An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
|
381
|
+
attr_accessor :transfer_data
|
382
|
+
# A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
|
383
|
+
attr_accessor :transfer_group
|
384
|
+
|
385
|
+
def initialize(
|
386
|
+
amount: nil,
|
387
|
+
application_fee: nil,
|
388
|
+
application_fee_amount: nil,
|
389
|
+
expand: nil,
|
390
|
+
receipt_email: nil,
|
391
|
+
statement_descriptor: nil,
|
392
|
+
statement_descriptor_suffix: nil,
|
393
|
+
transfer_data: nil,
|
394
|
+
transfer_group: nil
|
395
|
+
)
|
396
|
+
@amount = amount
|
397
|
+
@application_fee = application_fee
|
398
|
+
@application_fee_amount = application_fee_amount
|
399
|
+
@expand = expand
|
400
|
+
@receipt_email = receipt_email
|
401
|
+
@statement_descriptor = statement_descriptor
|
402
|
+
@statement_descriptor_suffix = statement_descriptor_suffix
|
403
|
+
@transfer_data = transfer_data
|
404
|
+
@transfer_group = transfer_group
|
405
|
+
end
|
406
|
+
end
|
407
|
+
|
6
408
|
# Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
|
7
409
|
#
|
8
410
|
# Uncaptured payments expire a set number of days after they are created ([7 by default](https://stripe.com/docs/charges/placing-a-hold)), after which they are marked as refunded and capture attempts will fail.
|
@@ -4,6 +4,24 @@
|
|
4
4
|
module Stripe
|
5
5
|
module Checkout
|
6
6
|
class SessionLineItemService < StripeService
|
7
|
+
class ListParams < Stripe::RequestParams
|
8
|
+
# 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.
|
9
|
+
attr_accessor :ending_before
|
10
|
+
# Specifies which fields in the response should be expanded.
|
11
|
+
attr_accessor :expand
|
12
|
+
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
13
|
+
attr_accessor :limit
|
14
|
+
# 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.
|
15
|
+
attr_accessor :starting_after
|
16
|
+
|
17
|
+
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil)
|
18
|
+
@ending_before = ending_before
|
19
|
+
@expand = expand
|
20
|
+
@limit = limit
|
21
|
+
@starting_after = starting_after
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
7
25
|
# When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
|
8
26
|
def list(session, params = {}, opts = {})
|
9
27
|
request(
|