stripe 15.6.0.pre.beta.1 → 16.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/lib/stripe/api_requestor.rb +5 -34
- data/lib/stripe/api_resource.rb +3 -0
- data/lib/stripe/api_version.rb +2 -1
- data/lib/stripe/errors.rb +0 -60
- data/lib/stripe/event_types.rb +20 -108
- data/lib/stripe/events/unknown_event_notification.rb +19 -0
- data/lib/stripe/events/v1_billing_meter_error_report_triggered_event.rb +115 -15
- data/lib/stripe/events/v1_billing_meter_no_meter_found_event.rb +93 -6
- data/lib/stripe/events/v2_core_event_destination_ping_event.rb +35 -12
- data/lib/stripe/object_types.rb +2 -54
- data/lib/stripe/params/account_capability_list_params.rb +13 -0
- data/lib/stripe/params/account_capability_retrieve_params.rb +13 -0
- data/lib/stripe/params/account_capability_update_params.rb +18 -0
- data/lib/stripe/params/account_create_params.rb +2083 -0
- data/lib/stripe/params/account_delete_params.rb +6 -0
- data/lib/stripe/params/account_external_account_create_params.rb +134 -0
- data/lib/stripe/params/account_external_account_delete_params.rb +6 -0
- data/lib/stripe/params/account_external_account_list_params.rb +25 -0
- data/lib/stripe/params/account_external_account_retrieve_params.rb +13 -0
- data/lib/stripe/params/account_external_account_update_params.rb +91 -0
- data/lib/stripe/params/account_link_create_params.rb +52 -0
- data/lib/stripe/params/account_list_params.rb +42 -0
- data/lib/stripe/params/account_login_link_create_params.rb +13 -0
- data/lib/stripe/params/account_person_create_params.rb +435 -0
- data/lib/stripe/params/account_person_delete_params.rb +6 -0
- data/lib/stripe/params/account_person_list_params.rb +61 -0
- data/lib/stripe/params/account_person_retrieve_params.rb +13 -0
- data/lib/stripe/params/account_person_update_params.rb +435 -0
- data/lib/stripe/params/account_persons_params.rb +61 -0
- data/lib/stripe/params/account_reject_params.rb +16 -0
- data/lib/stripe/params/account_retrieve_current_params.rb +13 -0
- data/lib/stripe/params/account_retrieve_params.rb +13 -0
- data/lib/stripe/params/account_session_create_params.rb +598 -0
- data/lib/stripe/params/account_update_params.rb +2030 -0
- data/lib/stripe/params/apple_pay_domain_create_params.rb +16 -0
- data/lib/stripe/params/apple_pay_domain_delete_params.rb +6 -0
- data/lib/stripe/params/apple_pay_domain_list_params.rb +31 -0
- data/lib/stripe/params/apple_pay_domain_retrieve_params.rb +13 -0
- data/lib/stripe/params/application_fee_list_params.rb +52 -0
- data/lib/stripe/params/application_fee_refund_create_params.rb +19 -0
- data/lib/stripe/params/application_fee_refund_list_params.rb +22 -0
- data/lib/stripe/params/application_fee_refund_retrieve_params.rb +13 -0
- data/lib/stripe/params/application_fee_refund_update_params.rb +16 -0
- data/lib/stripe/params/application_fee_retrieve_params.rb +13 -0
- data/lib/stripe/params/apps/secret_create_params.rb +38 -0
- data/lib/stripe/params/apps/secret_delete_where_params.rb +32 -0
- data/lib/stripe/params/apps/secret_find_params.rb +32 -0
- data/lib/stripe/{services/quote_line_service.rb → params/apps/secret_list_params.rb} +17 -14
- data/lib/stripe/params/balance_retrieve_params.rb +13 -0
- data/lib/stripe/params/balance_settings_retrieve_params.rb +13 -0
- data/lib/stripe/params/balance_settings_update_params.rb +67 -0
- data/lib/stripe/params/balance_transaction_list_params.rb +64 -0
- data/lib/stripe/params/balance_transaction_retrieve_params.rb +13 -0
- data/lib/stripe/params/billing/alert_activate_params.rb +15 -0
- data/lib/stripe/params/billing/alert_archive_params.rb +15 -0
- data/lib/stripe/params/billing/alert_create_params.rb +52 -0
- data/lib/stripe/params/billing/alert_deactivate_params.rb +15 -0
- data/lib/stripe/params/billing/alert_list_params.rb +37 -0
- data/lib/stripe/params/billing/alert_retrieve_params.rb +15 -0
- data/lib/stripe/params/billing/credit_balance_summary_retrieve_params.rb +54 -0
- data/lib/stripe/params/billing/credit_balance_transaction_list_params.rb +37 -0
- data/lib/stripe/params/billing/credit_balance_transaction_retrieve_params.rb +15 -0
- data/lib/stripe/params/billing/credit_grant_create_params.rb +103 -0
- data/lib/stripe/params/billing/credit_grant_expire_params.rb +15 -0
- data/lib/stripe/params/billing/credit_grant_list_params.rb +33 -0
- data/lib/stripe/params/billing/credit_grant_retrieve_params.rb +15 -0
- data/lib/stripe/params/billing/credit_grant_update_params.rb +21 -0
- data/lib/stripe/params/billing/credit_grant_void_grant_params.rb +15 -0
- data/lib/stripe/params/billing/meter_create_params.rb +70 -0
- data/lib/stripe/params/billing/meter_deactivate_params.rb +15 -0
- data/lib/stripe/params/billing/meter_event_adjustment_create_params.rb +32 -0
- data/lib/stripe/params/billing/meter_event_create_params.rb +27 -0
- data/lib/stripe/params/billing/meter_event_summary_list_params.rb +45 -0
- data/lib/stripe/params/billing/meter_list_params.rb +27 -0
- data/lib/stripe/params/billing/meter_reactivate_params.rb +15 -0
- data/lib/stripe/params/billing/meter_retrieve_params.rb +15 -0
- data/lib/stripe/params/billing/meter_update_params.rb +18 -0
- data/lib/stripe/params/billing_portal/configuration_create_params.rb +225 -0
- data/lib/stripe/params/billing_portal/configuration_list_params.rb +37 -0
- data/lib/stripe/params/billing_portal/configuration_retrieve_params.rb +15 -0
- data/lib/stripe/params/billing_portal/configuration_update_params.rb +231 -0
- data/lib/stripe/params/billing_portal/session_create_params.rb +179 -0
- data/lib/stripe/params/charge_capture_params.rb +57 -0
- data/lib/stripe/params/charge_create_params.rb +172 -0
- data/lib/stripe/params/charge_list_params.rb +60 -0
- data/lib/stripe/params/charge_retrieve_params.rb +13 -0
- data/lib/stripe/params/charge_search_params.rb +22 -0
- data/lib/stripe/params/charge_update_params.rb +102 -0
- data/lib/stripe/params/checkout/session_create_params.rb +2445 -0
- data/lib/stripe/params/checkout/session_expire_params.rb +15 -0
- data/lib/stripe/{services/quote_preview_subscription_schedule_service.rb → params/checkout/session_line_item_list_params.rb} +2 -13
- data/lib/stripe/{services/order_line_item_service.rb → params/checkout/session_list_line_items_params.rb} +2 -13
- data/lib/stripe/params/checkout/session_list_params.rb +83 -0
- data/lib/stripe/params/checkout/session_retrieve_params.rb +15 -0
- data/lib/stripe/params/checkout/session_update_params.rb +179 -0
- data/lib/stripe/params/climate/order_cancel_params.rb +15 -0
- data/lib/stripe/params/climate/order_create_params.rb +49 -0
- data/lib/stripe/params/climate/order_list_params.rb +24 -0
- data/lib/stripe/params/climate/order_retrieve_params.rb +15 -0
- data/lib/stripe/params/climate/order_update_params.rb +29 -0
- data/lib/stripe/params/climate/product_list_params.rb +24 -0
- data/lib/stripe/params/climate/product_retrieve_params.rb +15 -0
- data/lib/stripe/params/climate/supplier_list_params.rb +24 -0
- data/lib/stripe/params/climate/supplier_retrieve_params.rb +15 -0
- data/lib/stripe/params/confirmation_token_create_params.rb +650 -0
- data/lib/stripe/params/confirmation_token_retrieve_params.rb +13 -0
- data/lib/stripe/params/country_spec_list_params.rb +22 -0
- data/lib/stripe/params/country_spec_retrieve_params.rb +13 -0
- data/lib/stripe/params/coupon_create_params.rb +80 -0
- data/lib/stripe/params/coupon_delete_params.rb +6 -0
- data/lib/stripe/params/coupon_list_params.rb +42 -0
- data/lib/stripe/params/coupon_retrieve_params.rb +13 -0
- data/lib/stripe/params/coupon_update_params.rb +30 -0
- data/lib/stripe/params/credit_note_create_params.rb +144 -0
- data/lib/stripe/params/credit_note_line_item_list_params.rb +22 -0
- data/lib/stripe/params/credit_note_list_params.rb +56 -0
- data/lib/stripe/params/credit_note_list_preview_line_items_params.rb +156 -0
- data/lib/stripe/params/credit_note_preview_lines_list_params.rb +156 -0
- data/lib/stripe/params/credit_note_preview_params.rb +144 -0
- data/lib/stripe/params/credit_note_retrieve_params.rb +13 -0
- data/lib/stripe/params/credit_note_update_params.rb +19 -0
- data/lib/stripe/params/credit_note_void_credit_note_params.rb +13 -0
- data/lib/stripe/params/customer_balance_transaction_create_params.rb +25 -0
- data/lib/stripe/params/customer_balance_transaction_list_params.rb +22 -0
- data/lib/stripe/params/customer_balance_transaction_retrieve_params.rb +13 -0
- data/lib/stripe/params/customer_balance_transaction_update_params.rb +19 -0
- data/lib/stripe/params/customer_cash_balance_retrieve_params.rb +13 -0
- data/lib/stripe/params/customer_cash_balance_transaction_list_params.rb +22 -0
- data/lib/stripe/params/customer_cash_balance_transaction_retrieve_params.rb +13 -0
- data/lib/stripe/params/customer_cash_balance_update_params.rb +24 -0
- data/lib/stripe/params/customer_create_funding_instructions_params.rb +46 -0
- data/lib/stripe/params/customer_create_params.rb +259 -0
- data/lib/stripe/params/customer_delete_discount_params.rb +6 -0
- data/lib/stripe/params/customer_delete_params.rb +6 -0
- data/lib/stripe/params/customer_fund_cash_balance_params.rb +22 -0
- data/lib/stripe/params/customer_funding_instructions_create_params.rb +46 -0
- data/lib/stripe/params/customer_list_params.rb +56 -0
- data/lib/stripe/params/customer_list_payment_methods_params.rb +35 -0
- data/lib/stripe/params/customer_payment_method_list_params.rb +35 -0
- data/lib/stripe/params/customer_payment_method_retrieve_params.rb +13 -0
- data/lib/stripe/params/customer_payment_source_create_params.rb +22 -0
- data/lib/stripe/params/customer_payment_source_delete_params.rb +13 -0
- data/lib/stripe/params/customer_payment_source_list_params.rb +25 -0
- data/lib/stripe/params/customer_payment_source_retrieve_params.rb +13 -0
- data/lib/stripe/params/customer_payment_source_update_params.rb +114 -0
- data/lib/stripe/params/customer_payment_source_verify_params.rb +16 -0
- data/lib/stripe/params/customer_retrieve_params.rb +13 -0
- data/lib/stripe/params/customer_retrieve_payment_method_params.rb +13 -0
- data/lib/stripe/params/customer_search_params.rb +22 -0
- data/lib/stripe/params/customer_session_create_params.rb +100 -0
- data/lib/stripe/params/customer_tax_id_create_params.rb +19 -0
- data/lib/stripe/params/customer_tax_id_delete_params.rb +6 -0
- data/lib/stripe/params/customer_tax_id_list_params.rb +22 -0
- data/lib/stripe/params/customer_tax_id_retrieve_params.rb +13 -0
- data/lib/stripe/params/customer_update_params.rb +243 -0
- data/lib/stripe/params/dispute_close_params.rb +13 -0
- data/lib/stripe/params/dispute_list_params.rb +56 -0
- data/lib/stripe/params/dispute_retrieve_params.rb +13 -0
- data/lib/stripe/params/dispute_update_params.rb +308 -0
- data/lib/stripe/params/entitlements/active_entitlement_list_params.rb +33 -0
- data/lib/stripe/params/entitlements/active_entitlement_retrieve_params.rb +15 -0
- data/lib/stripe/params/entitlements/feature_create_params.rb +24 -0
- data/lib/stripe/params/entitlements/feature_list_params.rb +37 -0
- data/lib/stripe/params/entitlements/feature_retrieve_params.rb +15 -0
- data/lib/stripe/params/entitlements/feature_update_params.rb +24 -0
- data/lib/stripe/params/ephemeral_key_create_params.rb +31 -0
- data/lib/stripe/params/ephemeral_key_delete_params.rb +13 -0
- data/lib/stripe/params/event_list_params.rb +60 -0
- data/lib/stripe/params/event_retrieve_params.rb +13 -0
- data/lib/stripe/params/exchange_rate_list_params.rb +22 -0
- data/lib/stripe/params/exchange_rate_retrieve_params.rb +13 -0
- data/lib/stripe/params/file_create_params.rb +36 -0
- data/lib/stripe/params/file_link_create_params.rb +22 -0
- data/lib/stripe/params/file_link_list_params.rb +56 -0
- data/lib/stripe/params/file_link_retrieve_params.rb +13 -0
- data/lib/stripe/params/file_link_update_params.rb +19 -0
- data/lib/stripe/params/file_list_params.rb +52 -0
- data/lib/stripe/params/file_retrieve_params.rb +13 -0
- data/lib/stripe/params/financial_connections/account_disconnect_params.rb +15 -0
- data/lib/stripe/params/financial_connections/account_list_owners_params.rb +33 -0
- data/lib/stripe/params/financial_connections/account_list_params.rb +48 -0
- data/lib/stripe/params/financial_connections/account_owner_list_params.rb +33 -0
- data/lib/stripe/params/financial_connections/account_refresh_account_params.rb +18 -0
- data/lib/stripe/params/financial_connections/account_refresh_params.rb +18 -0
- data/lib/stripe/params/financial_connections/account_retrieve_params.rb +15 -0
- data/lib/stripe/params/financial_connections/account_subscribe_params.rb +18 -0
- data/lib/stripe/params/financial_connections/account_unsubscribe_params.rb +18 -0
- data/lib/stripe/params/financial_connections/session_create_params.rb +65 -0
- data/lib/stripe/params/financial_connections/session_retrieve_params.rb +15 -0
- data/lib/stripe/params/financial_connections/transaction_list_params.rb +67 -0
- data/lib/stripe/params/financial_connections/transaction_retrieve_params.rb +15 -0
- data/lib/stripe/params/forwarding/request_create_params.rb +59 -0
- data/lib/stripe/params/forwarding/request_list_params.rb +44 -0
- data/lib/stripe/params/forwarding/request_retrieve_params.rb +15 -0
- data/lib/stripe/params/identity/verification_report_list_params.rb +62 -0
- data/lib/stripe/params/identity/verification_report_retrieve_params.rb +15 -0
- data/lib/stripe/params/identity/verification_session_cancel_params.rb +15 -0
- data/lib/stripe/params/identity/verification_session_create_params.rb +107 -0
- data/lib/stripe/params/identity/verification_session_list_params.rb +62 -0
- data/lib/stripe/params/identity/verification_session_redact_params.rb +15 -0
- data/lib/stripe/params/identity/verification_session_retrieve_params.rb +15 -0
- data/lib/stripe/params/identity/verification_session_update_params.rb +69 -0
- data/lib/stripe/params/invoice_add_lines_params.rb +231 -0
- data/lib/stripe/params/invoice_attach_payment_params.rb +16 -0
- data/lib/stripe/params/invoice_create_params.rb +589 -0
- data/lib/stripe/params/invoice_create_preview_params.rb +993 -0
- data/lib/stripe/params/invoice_delete_params.rb +6 -0
- data/lib/stripe/params/invoice_finalize_invoice_params.rb +16 -0
- data/lib/stripe/params/invoice_item_create_params.rb +145 -0
- data/lib/stripe/params/invoice_item_delete_params.rb +6 -0
- data/lib/stripe/params/invoice_item_list_params.rb +60 -0
- data/lib/stripe/params/invoice_item_retrieve_params.rb +13 -0
- data/lib/stripe/params/invoice_item_update_params.rb +129 -0
- data/lib/stripe/params/invoice_line_item_list_params.rb +22 -0
- data/lib/stripe/params/invoice_line_item_update_params.rb +217 -0
- data/lib/stripe/params/invoice_list_params.rb +86 -0
- data/lib/stripe/params/invoice_mark_uncollectible_params.rb +13 -0
- data/lib/stripe/params/invoice_pay_params.rb +41 -0
- data/lib/stripe/params/invoice_payment_list_params.rb +50 -0
- data/lib/stripe/params/invoice_payment_retrieve_params.rb +13 -0
- data/lib/stripe/params/invoice_remove_lines_params.rb +30 -0
- data/lib/stripe/params/invoice_rendering_template_archive_params.rb +13 -0
- data/lib/stripe/params/invoice_rendering_template_list_params.rb +25 -0
- data/lib/stripe/params/invoice_rendering_template_retrieve_params.rb +16 -0
- data/lib/stripe/params/invoice_rendering_template_unarchive_params.rb +13 -0
- data/lib/stripe/params/invoice_retrieve_params.rb +13 -0
- data/lib/stripe/params/invoice_search_params.rb +22 -0
- data/lib/stripe/params/invoice_send_invoice_params.rb +13 -0
- data/lib/stripe/params/invoice_update_lines_params.rb +231 -0
- data/lib/stripe/params/invoice_update_params.rb +557 -0
- data/lib/stripe/params/invoice_void_invoice_params.rb +13 -0
- data/lib/stripe/params/issuing/authorization_approve_params.rb +21 -0
- data/lib/stripe/params/issuing/authorization_capture_params.rb +265 -0
- data/lib/stripe/params/issuing/authorization_create_params.rb +357 -0
- data/lib/stripe/params/issuing/authorization_decline_params.rb +18 -0
- data/lib/stripe/params/issuing/authorization_expire_params.rb +15 -0
- data/lib/stripe/params/issuing/authorization_finalize_amount_params.rb +143 -0
- data/lib/stripe/params/issuing/authorization_increment_params.rb +21 -0
- data/lib/stripe/params/issuing/authorization_list_params.rb +62 -0
- data/lib/stripe/params/issuing/authorization_respond_params.rb +18 -0
- data/lib/stripe/params/issuing/authorization_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/authorization_reverse_params.rb +18 -0
- data/lib/stripe/params/issuing/authorization_update_params.rb +18 -0
- data/lib/stripe/params/issuing/card_create_params.rb +213 -0
- data/lib/stripe/params/issuing/card_deliver_card_params.rb +15 -0
- data/lib/stripe/params/issuing/card_fail_card_params.rb +15 -0
- data/lib/stripe/params/issuing/card_list_params.rb +78 -0
- data/lib/stripe/params/issuing/card_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/card_return_card_params.rb +15 -0
- data/lib/stripe/params/issuing/card_ship_card_params.rb +15 -0
- data/lib/stripe/params/issuing/card_submit_card_params.rb +15 -0
- data/lib/stripe/params/issuing/card_update_params.rb +181 -0
- data/lib/stripe/params/issuing/cardholder_create_params.rb +238 -0
- data/lib/stripe/params/issuing/cardholder_list_params.rb +66 -0
- data/lib/stripe/params/issuing/cardholder_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/cardholder_update_params.rb +230 -0
- data/lib/stripe/params/issuing/dispute_create_params.rb +297 -0
- data/lib/stripe/params/issuing/dispute_list_params.rb +58 -0
- data/lib/stripe/params/issuing/dispute_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/dispute_submit_params.rb +18 -0
- data/lib/stripe/params/issuing/dispute_update_params.rb +275 -0
- data/lib/stripe/params/issuing/personalization_design_activate_params.rb +15 -0
- data/lib/stripe/params/issuing/personalization_design_create_params.rb +75 -0
- data/lib/stripe/params/issuing/personalization_design_deactivate_params.rb +15 -0
- data/lib/stripe/params/issuing/personalization_design_list_params.rb +52 -0
- data/lib/stripe/params/issuing/personalization_design_reject_params.rb +29 -0
- data/lib/stripe/params/issuing/personalization_design_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/personalization_design_update_params.rb +75 -0
- data/lib/stripe/params/issuing/physical_bundle_list_params.rb +37 -0
- data/lib/stripe/params/issuing/physical_bundle_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/token_list_params.rb +58 -0
- data/lib/stripe/params/issuing/token_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/token_update_params.rb +18 -0
- data/lib/stripe/params/issuing/transaction_create_force_capture_params.rb +316 -0
- data/lib/stripe/params/issuing/transaction_create_unlinked_refund_params.rb +316 -0
- data/lib/stripe/params/issuing/transaction_list_params.rb +62 -0
- data/lib/stripe/params/issuing/transaction_refund_params.rb +18 -0
- data/lib/stripe/params/issuing/transaction_retrieve_params.rb +15 -0
- data/lib/stripe/params/issuing/transaction_update_params.rb +18 -0
- data/lib/stripe/params/mandate_retrieve_params.rb +13 -0
- data/lib/stripe/params/payment_intent_apply_customer_balance_params.rb +23 -0
- data/lib/stripe/params/payment_intent_cancel_params.rb +16 -0
- data/lib/stripe/params/payment_intent_capture_params.rb +54 -0
- data/lib/stripe/params/payment_intent_confirm_params.rb +2379 -0
- data/lib/stripe/params/payment_intent_create_params.rb +2480 -0
- data/lib/stripe/params/payment_intent_increment_authorization_params.rb +48 -0
- data/lib/stripe/params/payment_intent_list_params.rb +52 -0
- data/lib/stripe/params/payment_intent_retrieve_params.rb +16 -0
- data/lib/stripe/params/payment_intent_search_params.rb +22 -0
- data/lib/stripe/params/payment_intent_update_params.rb +2353 -0
- data/lib/stripe/params/payment_intent_verify_microdeposits_params.rb +19 -0
- data/lib/stripe/params/payment_link_create_params.rb +776 -0
- data/lib/stripe/params/payment_link_line_item_list_params.rb +22 -0
- data/lib/stripe/params/payment_link_list_line_items_params.rb +22 -0
- data/lib/stripe/params/payment_link_list_params.rb +25 -0
- data/lib/stripe/params/payment_link_retrieve_params.rb +13 -0
- data/lib/stripe/params/payment_link_update_params.rb +564 -0
- data/lib/stripe/params/payment_method_attach_params.rb +16 -0
- data/lib/stripe/params/payment_method_configuration_create_params.rb +1135 -0
- data/lib/stripe/params/payment_method_configuration_list_params.rb +31 -0
- data/lib/stripe/params/payment_method_configuration_retrieve_params.rb +13 -0
- data/lib/stripe/params/payment_method_configuration_update_params.rb +1135 -0
- data/lib/stripe/params/payment_method_create_params.rb +583 -0
- data/lib/stripe/params/payment_method_detach_params.rb +13 -0
- data/lib/stripe/params/payment_method_domain_create_params.rb +19 -0
- data/lib/stripe/params/payment_method_domain_list_params.rb +35 -0
- data/lib/stripe/params/payment_method_domain_retrieve_params.rb +13 -0
- data/lib/stripe/params/payment_method_domain_update_params.rb +16 -0
- data/lib/stripe/params/payment_method_domain_validate_params.rb +13 -0
- data/lib/stripe/params/payment_method_list_params.rb +35 -0
- data/lib/stripe/params/payment_method_retrieve_params.rb +13 -0
- data/lib/stripe/params/payment_method_update_params.rb +120 -0
- data/lib/stripe/params/payout_cancel_params.rb +13 -0
- data/lib/stripe/params/payout_create_params.rb +51 -0
- data/lib/stripe/params/payout_list_params.rb +78 -0
- data/lib/stripe/params/payout_retrieve_params.rb +13 -0
- data/lib/stripe/params/payout_reverse_params.rb +16 -0
- data/lib/stripe/params/payout_update_params.rb +16 -0
- data/lib/stripe/params/plan_create_params.rb +158 -0
- data/lib/stripe/params/plan_delete_params.rb +6 -0
- data/lib/stripe/params/plan_list_params.rb +56 -0
- data/lib/stripe/params/plan_retrieve_params.rb +13 -0
- data/lib/stripe/params/plan_update_params.rb +35 -0
- data/lib/stripe/params/price_create_params.rb +278 -0
- data/lib/stripe/params/price_list_params.rb +87 -0
- data/lib/stripe/params/price_retrieve_params.rb +13 -0
- data/lib/stripe/params/price_search_params.rb +22 -0
- data/lib/stripe/params/price_update_params.rb +113 -0
- data/lib/stripe/params/product_create_params.rb +243 -0
- data/lib/stripe/params/product_delete_params.rb +6 -0
- data/lib/stripe/params/product_feature_create_params.rb +16 -0
- data/lib/stripe/params/product_feature_delete_params.rb +6 -0
- data/lib/stripe/params/product_feature_list_params.rb +22 -0
- data/lib/stripe/params/product_feature_retrieve_params.rb +13 -0
- data/lib/stripe/params/product_list_params.rb +68 -0
- data/lib/stripe/params/product_retrieve_params.rb +13 -0
- data/lib/stripe/params/product_search_params.rb +22 -0
- data/lib/stripe/params/product_update_params.rb +96 -0
- data/lib/stripe/params/promotion_code_create_params.rb +91 -0
- data/lib/stripe/params/promotion_code_list_params.rb +64 -0
- data/lib/stripe/params/promotion_code_retrieve_params.rb +13 -0
- data/lib/stripe/params/promotion_code_update_params.rb +38 -0
- data/lib/stripe/params/quote_accept_params.rb +13 -0
- data/lib/stripe/params/quote_cancel_params.rb +13 -0
- data/lib/stripe/params/quote_computed_upfront_line_items_list_params.rb +22 -0
- data/lib/stripe/params/quote_create_params.rb +301 -0
- data/lib/stripe/params/quote_finalize_quote_params.rb +16 -0
- data/lib/stripe/params/quote_line_item_list_params.rb +22 -0
- data/lib/stripe/params/quote_list_computed_upfront_line_items_params.rb +22 -0
- data/lib/stripe/params/quote_list_line_items_params.rb +22 -0
- data/lib/stripe/params/quote_list_params.rb +39 -0
- data/lib/stripe/params/quote_pdf_params.rb +13 -0
- data/lib/stripe/params/quote_retrieve_params.rb +13 -0
- data/lib/stripe/params/quote_update_params.rb +263 -0
- data/lib/stripe/params/radar/early_fraud_warning_list_params.rb +58 -0
- data/lib/stripe/params/radar/early_fraud_warning_retrieve_params.rb +15 -0
- data/lib/stripe/params/radar/value_list_create_params.rb +27 -0
- data/lib/stripe/params/radar/value_list_delete_params.rb +8 -0
- data/lib/stripe/params/radar/value_list_item_create_params.rb +21 -0
- data/lib/stripe/params/radar/value_list_item_delete_params.rb +8 -0
- data/lib/stripe/params/radar/value_list_item_list_params.rb +58 -0
- data/lib/stripe/params/radar/value_list_item_retrieve_params.rb +15 -0
- data/lib/stripe/params/radar/value_list_list_params.rb +58 -0
- data/lib/stripe/params/radar/value_list_retrieve_params.rb +15 -0
- data/lib/stripe/params/radar/value_list_update_params.rb +24 -0
- data/lib/stripe/params/refund_cancel_params.rb +13 -0
- data/lib/stripe/params/refund_create_params.rb +59 -0
- data/lib/stripe/params/refund_expire_params.rb +13 -0
- data/lib/stripe/params/refund_list_params.rb +56 -0
- data/lib/stripe/params/refund_retrieve_params.rb +13 -0
- data/lib/stripe/params/refund_update_params.rb +16 -0
- data/lib/stripe/params/reporting/report_run_create_params.rb +59 -0
- data/lib/stripe/params/reporting/report_run_list_params.rb +44 -0
- data/lib/stripe/params/reporting/report_run_retrieve_params.rb +15 -0
- data/lib/stripe/params/reporting/report_type_list_params.rb +15 -0
- data/lib/stripe/params/reporting/report_type_retrieve_params.rb +15 -0
- data/lib/stripe/params/review_approve_params.rb +13 -0
- data/lib/stripe/params/review_list_params.rb +42 -0
- data/lib/stripe/params/review_retrieve_params.rb +13 -0
- data/lib/stripe/params/setup_attempt_list_params.rb +55 -0
- data/lib/stripe/params/setup_intent_cancel_params.rb +16 -0
- data/lib/stripe/params/setup_intent_confirm_params.rb +1050 -0
- data/lib/stripe/params/setup_intent_create_params.rb +1130 -0
- data/lib/stripe/params/setup_intent_list_params.rb +62 -0
- data/lib/stripe/params/setup_intent_retrieve_params.rb +16 -0
- data/lib/stripe/params/setup_intent_update_params.rb +1025 -0
- data/lib/stripe/params/setup_intent_verify_microdeposits_params.rb +19 -0
- data/lib/stripe/params/shipping_rate_create_params.rb +103 -0
- data/lib/stripe/params/shipping_rate_list_params.rb +56 -0
- data/lib/stripe/params/shipping_rate_retrieve_params.rb +13 -0
- data/lib/stripe/params/shipping_rate_update_params.rb +44 -0
- data/lib/stripe/params/sigma/scheduled_query_run_list_params.rb +24 -0
- data/lib/stripe/params/sigma/scheduled_query_run_retrieve_params.rb +15 -0
- data/lib/stripe/params/source_create_params.rb +317 -0
- data/lib/stripe/params/source_detach_params.rb +13 -0
- data/lib/stripe/params/source_retrieve_params.rb +16 -0
- data/lib/stripe/params/source_transaction_list_params.rb +22 -0
- data/lib/stripe/params/source_update_params.rb +259 -0
- data/lib/stripe/params/source_verify_params.rb +16 -0
- data/lib/stripe/params/subscription_cancel_params.rb +33 -0
- data/lib/stripe/params/subscription_create_params.rb +704 -0
- data/lib/stripe/params/subscription_delete_discount_params.rb +6 -0
- data/lib/stripe/params/subscription_item_create_params.rb +134 -0
- data/lib/stripe/params/subscription_item_delete_params.rb +19 -0
- data/lib/stripe/params/subscription_item_list_params.rb +31 -0
- data/lib/stripe/params/subscription_item_retrieve_params.rb +13 -0
- data/lib/stripe/params/subscription_item_update_params.rb +134 -0
- data/lib/stripe/params/subscription_list_params.rb +129 -0
- data/lib/stripe/params/subscription_migrate_params.rb +35 -0
- data/lib/stripe/params/subscription_resume_params.rb +27 -0
- data/lib/stripe/params/subscription_retrieve_params.rb +13 -0
- data/lib/stripe/params/subscription_schedule_cancel_params.rb +19 -0
- data/lib/stripe/params/subscription_schedule_create_params.rb +590 -0
- data/lib/stripe/params/subscription_schedule_list_params.rb +122 -0
- data/lib/stripe/params/subscription_schedule_release_params.rb +16 -0
- data/lib/stripe/params/subscription_schedule_retrieve_params.rb +13 -0
- data/lib/stripe/params/subscription_schedule_update_params.rb +562 -0
- data/lib/stripe/params/subscription_search_params.rb +22 -0
- data/lib/stripe/params/subscription_update_params.rb +683 -0
- data/lib/stripe/params/tax/calculation_create_params.rb +206 -0
- data/lib/stripe/params/tax/calculation_line_item_list_params.rb +24 -0
- data/lib/stripe/{services/quote_preview_invoice_service.rb → params/tax/calculation_list_line_items_params.rb} +2 -13
- data/lib/stripe/params/tax/calculation_retrieve_params.rb +15 -0
- data/lib/stripe/params/tax/registration_create_params.rb +2018 -0
- data/lib/stripe/params/tax/registration_list_params.rb +27 -0
- data/lib/stripe/params/tax/registration_retrieve_params.rb +15 -0
- data/lib/stripe/params/tax/registration_update_params.rb +21 -0
- data/lib/stripe/params/tax/settings_retrieve_params.rb +15 -0
- data/lib/stripe/params/tax/settings_update_params.rb +71 -0
- data/lib/stripe/params/tax/transaction_create_from_calculation_params.rb +27 -0
- data/lib/stripe/params/tax/transaction_create_reversal_params.rb +87 -0
- data/lib/stripe/params/tax/transaction_line_item_list_params.rb +24 -0
- data/lib/stripe/{services/payment_intent_amount_details_line_item_service.rb → params/tax/transaction_list_line_items_params.rb} +2 -13
- data/lib/stripe/params/tax/transaction_retrieve_params.rb +15 -0
- data/lib/stripe/params/tax_code_list_params.rb +22 -0
- data/lib/stripe/params/tax_code_retrieve_params.rb +13 -0
- data/lib/stripe/params/tax_id_create_params.rb +36 -0
- data/lib/stripe/params/tax_id_delete_params.rb +6 -0
- data/lib/stripe/params/tax_id_list_params.rb +39 -0
- data/lib/stripe/params/tax_id_retrieve_params.rb +13 -0
- data/lib/stripe/params/tax_rate_create_params.rb +55 -0
- data/lib/stripe/params/tax_rate_list_params.rb +56 -0
- data/lib/stripe/params/tax_rate_retrieve_params.rb +13 -0
- data/lib/stripe/params/tax_rate_update_params.rb +47 -0
- data/lib/stripe/params/terminal/configuration_create_params.rb +593 -0
- data/lib/stripe/params/terminal/configuration_delete_params.rb +8 -0
- data/lib/stripe/params/terminal/configuration_list_params.rb +33 -0
- data/lib/stripe/params/terminal/configuration_retrieve_params.rb +15 -0
- data/lib/stripe/params/terminal/configuration_update_params.rb +593 -0
- data/lib/stripe/params/terminal/connection_token_create_params.rb +18 -0
- data/lib/stripe/params/terminal/location_create_params.rb +153 -0
- data/lib/stripe/params/terminal/location_delete_params.rb +8 -0
- data/lib/stripe/params/terminal/location_list_params.rb +24 -0
- data/lib/stripe/params/terminal/location_retrieve_params.rb +15 -0
- data/lib/stripe/params/terminal/location_update_params.rb +153 -0
- data/lib/stripe/params/terminal/reader_cancel_action_params.rb +15 -0
- data/lib/stripe/params/terminal/reader_collect_inputs_params.rb +96 -0
- data/lib/stripe/params/terminal/reader_collect_payment_method_params.rb +51 -0
- data/lib/stripe/params/terminal/reader_confirm_payment_intent_params.rb +29 -0
- data/lib/stripe/params/terminal/reader_create_params.rb +27 -0
- data/lib/stripe/params/terminal/reader_delete_params.rb +8 -0
- data/lib/stripe/params/terminal/reader_list_params.rb +45 -0
- data/lib/stripe/params/terminal/reader_present_payment_method_params.rb +72 -0
- data/lib/stripe/params/terminal/reader_process_payment_intent_params.rb +55 -0
- data/lib/stripe/params/terminal/reader_process_setup_intent_params.rb +32 -0
- data/lib/stripe/params/terminal/reader_refund_payment_params.rb +53 -0
- data/lib/stripe/params/terminal/reader_retrieve_params.rb +15 -0
- data/lib/stripe/params/terminal/reader_set_reader_display_params.rb +52 -0
- data/lib/stripe/params/terminal/reader_succeed_input_collection_params.rb +18 -0
- data/lib/stripe/params/terminal/reader_timeout_input_collection_params.rb +15 -0
- data/lib/stripe/params/terminal/reader_update_params.rb +21 -0
- data/lib/stripe/params/test_helpers/confirmation_token_create_params.rb +652 -0
- data/lib/stripe/params/test_helpers/customer_fund_cash_balance_params.rb +24 -0
- data/lib/stripe/params/test_helpers/issuing/authorization_capture_params.rb +267 -0
- data/lib/stripe/params/test_helpers/issuing/authorization_create_params.rb +359 -0
- data/lib/stripe/params/test_helpers/issuing/authorization_expire_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/authorization_finalize_amount_params.rb +145 -0
- data/lib/stripe/params/test_helpers/issuing/authorization_increment_params.rb +23 -0
- data/lib/stripe/params/test_helpers/issuing/authorization_respond_params.rb +20 -0
- data/lib/stripe/params/test_helpers/issuing/authorization_reverse_params.rb +20 -0
- data/lib/stripe/params/test_helpers/issuing/card_deliver_card_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/card_fail_card_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/card_return_card_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/card_ship_card_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/card_submit_card_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/personalization_design_activate_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/personalization_design_deactivate_params.rb +17 -0
- data/lib/stripe/params/test_helpers/issuing/personalization_design_reject_params.rb +31 -0
- data/lib/stripe/params/test_helpers/issuing/transaction_create_force_capture_params.rb +318 -0
- data/lib/stripe/params/test_helpers/issuing/transaction_create_unlinked_refund_params.rb +318 -0
- data/lib/stripe/params/test_helpers/issuing/transaction_refund_params.rb +20 -0
- data/lib/stripe/params/test_helpers/refund_expire_params.rb +15 -0
- data/lib/stripe/params/test_helpers/terminal/reader_present_payment_method_params.rb +74 -0
- data/lib/stripe/params/test_helpers/terminal/reader_succeed_input_collection_params.rb +20 -0
- data/lib/stripe/params/test_helpers/terminal/reader_timeout_input_collection_params.rb +17 -0
- data/lib/stripe/params/test_helpers/test_clock_advance_params.rb +18 -0
- data/lib/stripe/params/test_helpers/test_clock_create_params.rb +21 -0
- data/lib/stripe/params/test_helpers/test_clock_delete_params.rb +8 -0
- data/lib/stripe/params/test_helpers/test_clock_list_params.rb +24 -0
- data/lib/stripe/params/test_helpers/test_clock_retrieve_params.rb +15 -0
- data/lib/stripe/params/test_helpers/treasury/inbound_transfer_fail_params.rb +28 -0
- data/lib/stripe/params/test_helpers/treasury/inbound_transfer_return_inbound_transfer_params.rb +17 -0
- data/lib/stripe/params/test_helpers/treasury/inbound_transfer_succeed_params.rb +17 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_payment_fail_params.rb +17 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_payment_post_params.rb +17 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_payment_return_outbound_payment_params.rb +28 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_payment_update_params.rb +57 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_transfer_fail_params.rb +17 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_transfer_post_params.rb +17 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_transfer_return_outbound_transfer_params.rb +28 -0
- data/lib/stripe/params/test_helpers/treasury/outbound_transfer_update_params.rb +57 -0
- data/lib/stripe/params/test_helpers/treasury/received_credit_create_params.rb +68 -0
- data/lib/stripe/params/test_helpers/treasury/received_debit_create_params.rb +68 -0
- data/lib/stripe/params/token_create_params.rb +1191 -0
- data/lib/stripe/params/token_retrieve_params.rb +13 -0
- data/lib/stripe/params/topup_cancel_params.rb +13 -0
- data/lib/stripe/params/topup_create_params.rb +43 -0
- data/lib/stripe/params/topup_list_params.rb +74 -0
- data/lib/stripe/params/topup_retrieve_params.rb +13 -0
- data/lib/stripe/params/topup_update_params.rb +19 -0
- data/lib/stripe/params/transfer_create_params.rb +47 -0
- data/lib/stripe/params/transfer_list_params.rb +56 -0
- data/lib/stripe/params/transfer_retrieve_params.rb +13 -0
- data/lib/stripe/params/transfer_reversal_create_params.rb +31 -0
- data/lib/stripe/params/transfer_reversal_list_params.rb +22 -0
- data/lib/stripe/params/transfer_reversal_retrieve_params.rb +13 -0
- data/lib/stripe/params/transfer_reversal_update_params.rb +16 -0
- data/lib/stripe/params/transfer_update_params.rb +19 -0
- data/lib/stripe/params/treasury/credit_reversal_create_params.rb +21 -0
- data/lib/stripe/params/treasury/credit_reversal_list_params.rb +41 -0
- data/lib/stripe/params/treasury/credit_reversal_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/debit_reversal_create_params.rb +21 -0
- data/lib/stripe/params/treasury/debit_reversal_list_params.rb +45 -0
- data/lib/stripe/params/treasury/debit_reversal_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/financial_account_close_params.rb +32 -0
- data/lib/stripe/params/treasury/financial_account_create_params.rb +201 -0
- data/lib/stripe/params/treasury/financial_account_features_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/financial_account_features_update_params.rb +163 -0
- data/lib/stripe/params/treasury/financial_account_list_params.rb +54 -0
- data/lib/stripe/params/treasury/financial_account_retrieve_features_params.rb +15 -0
- data/lib/stripe/params/treasury/financial_account_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/financial_account_update_features_params.rb +163 -0
- data/lib/stripe/params/treasury/financial_account_update_params.rb +216 -0
- data/lib/stripe/params/treasury/inbound_transfer_cancel_params.rb +15 -0
- data/lib/stripe/params/treasury/inbound_transfer_create_params.rb +45 -0
- data/lib/stripe/params/treasury/inbound_transfer_fail_params.rb +26 -0
- data/lib/stripe/params/treasury/inbound_transfer_list_params.rb +37 -0
- data/lib/stripe/params/treasury/inbound_transfer_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/inbound_transfer_return_inbound_transfer_params.rb +15 -0
- data/lib/stripe/params/treasury/inbound_transfer_succeed_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_payment_cancel_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_payment_create_params.rb +190 -0
- data/lib/stripe/params/treasury/outbound_payment_fail_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_payment_list_params.rb +62 -0
- data/lib/stripe/params/treasury/outbound_payment_post_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_payment_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_payment_return_outbound_payment_params.rb +26 -0
- data/lib/stripe/params/treasury/outbound_payment_update_params.rb +55 -0
- data/lib/stripe/params/treasury/outbound_transfer_cancel_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_transfer_create_params.rb +81 -0
- data/lib/stripe/params/treasury/outbound_transfer_fail_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_transfer_list_params.rb +37 -0
- data/lib/stripe/params/treasury/outbound_transfer_post_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_transfer_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/outbound_transfer_return_outbound_transfer_params.rb +26 -0
- data/lib/stripe/params/treasury/outbound_transfer_update_params.rb +55 -0
- data/lib/stripe/params/treasury/received_credit_create_params.rb +66 -0
- data/lib/stripe/params/treasury/received_credit_list_params.rb +49 -0
- data/lib/stripe/params/treasury/received_credit_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/received_debit_create_params.rb +66 -0
- data/lib/stripe/params/treasury/received_debit_list_params.rb +37 -0
- data/lib/stripe/params/treasury/received_debit_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/transaction_entry_list_params.rb +84 -0
- data/lib/stripe/params/treasury/transaction_entry_retrieve_params.rb +15 -0
- data/lib/stripe/params/treasury/transaction_list_params.rb +92 -0
- data/lib/stripe/params/treasury/transaction_retrieve_params.rb +15 -0
- data/lib/stripe/params/v2/billing/meter_event_adjustment_create_params.rb +31 -0
- data/lib/stripe/params/v2/billing/meter_event_create_params.rb +33 -0
- data/lib/stripe/params/v2/billing/meter_event_session_create_params.rb +10 -0
- data/lib/stripe/params/v2/billing/meter_event_stream_create_params.rb +41 -0
- data/lib/stripe/params/v2/core/event_destination_create_params.rb +79 -0
- data/lib/stripe/params/v2/core/event_destination_delete_params.rb +10 -0
- data/lib/stripe/params/v2/core/event_destination_disable_params.rb +10 -0
- data/lib/stripe/params/v2/core/event_destination_enable_params.rb +10 -0
- data/lib/stripe/params/v2/core/event_destination_list_params.rb +20 -0
- data/lib/stripe/params/v2/core/event_destination_ping_params.rb +10 -0
- data/lib/stripe/params/v2/core/event_destination_retrieve_params.rb +17 -0
- data/lib/stripe/params/v2/core/event_destination_update_params.rb +47 -0
- data/lib/stripe/params/v2/core/event_list_params.rb +22 -0
- data/lib/stripe/params/v2/core/event_retrieve_params.rb +10 -0
- data/lib/stripe/params/webhook_endpoint_create_params.rb +39 -0
- data/lib/stripe/params/webhook_endpoint_delete_params.rb +6 -0
- data/lib/stripe/params/webhook_endpoint_list_params.rb +22 -0
- data/lib/stripe/params/webhook_endpoint_retrieve_params.rb +13 -0
- data/lib/stripe/params/webhook_endpoint_update_params.rb +35 -0
- data/lib/stripe/params.rb +588 -0
- data/lib/stripe/request_options.rb +14 -5
- data/lib/stripe/resources/account.rb +437 -4906
- data/lib/stripe/resources/account_link.rb +8 -47
- data/lib/stripe/resources/account_session.rb +338 -910
- data/lib/stripe/resources/apple_pay_domain.rb +8 -40
- data/lib/stripe/resources/application.rb +8 -0
- data/lib/stripe/resources/application_fee.rb +12 -44
- data/lib/stripe/resources/application_fee_refund.rb +8 -0
- data/lib/stripe/resources/apps/secret.rb +12 -112
- data/lib/stripe/resources/balance.rb +159 -0
- data/lib/stripe/resources/balance_settings.rb +40 -60
- data/lib/stripe/resources/balance_transaction.rb +12 -56
- data/lib/stripe/resources/bank_account.rb +40 -0
- data/lib/stripe/resources/billing/alert.rb +20 -100
- data/lib/stripe/resources/billing/alert_triggered.rb +8 -0
- data/lib/stripe/resources/billing/credit_balance_summary.rb +48 -2
- data/lib/stripe/resources/billing/credit_balance_transaction.rb +73 -33
- data/lib/stripe/resources/billing/credit_grant.rb +42 -161
- data/lib/stripe/resources/billing/meter.rb +40 -116
- data/lib/stripe/resources/billing/meter_event.rb +8 -20
- data/lib/stripe/resources/billing/meter_event_adjustment.rb +12 -22
- data/lib/stripe/resources/billing/meter_event_summary.rb +8 -0
- data/lib/stripe/resources/billing_portal/configuration.rb +120 -473
- data/lib/stripe/resources/billing_portal/session.rb +98 -176
- data/lib/stripe/resources/capability.rb +56 -0
- data/lib/stripe/resources/card.rb +17 -3
- data/lib/stripe/resources/cash_balance.rb +16 -2
- data/lib/stripe/resources/charge.rb +949 -1945
- data/lib/stripe/resources/checkout/session.rb +1038 -2991
- data/lib/stripe/resources/climate/order.rb +28 -89
- data/lib/stripe/resources/climate/product.rb +13 -15
- data/lib/stripe/resources/climate/supplier.rb +13 -15
- data/lib/stripe/resources/confirmation_token.rb +883 -841
- data/lib/stripe/resources/connect_collection_transfer.rb +8 -0
- data/lib/stripe/resources/country_spec.rb +29 -15
- data/lib/stripe/resources/coupon.rb +19 -166
- data/lib/stripe/resources/credit_note.rb +66 -510
- data/lib/stripe/resources/credit_note_line_item.rb +43 -8
- data/lib/stripe/resources/customer.rb +81 -677
- data/lib/stripe/resources/customer_balance_transaction.rb +8 -2
- data/lib/stripe/resources/customer_cash_balance_transaction.rb +108 -2
- data/lib/stripe/resources/customer_session.rb +49 -98
- data/lib/stripe/resources/discount.rb +24 -6
- data/lib/stripe/resources/dispute.rb +159 -376
- data/lib/stripe/resources/entitlements/active_entitlement.rb +8 -26
- data/lib/stripe/resources/entitlements/active_entitlement_summary.rb +8 -0
- data/lib/stripe/resources/entitlements/feature.rb +8 -66
- data/lib/stripe/resources/ephemeral_key.rb +8 -8
- data/lib/stripe/resources/event.rb +16 -79
- data/lib/stripe/resources/exchange_rate.rb +18 -17
- data/lib/stripe/resources/file.rb +8 -79
- data/lib/stripe/resources/file_link.rb +8 -84
- data/lib/stripe/resources/financial_connections/account.rb +65 -130
- data/lib/stripe/resources/financial_connections/account_owner.rb +8 -0
- data/lib/stripe/resources/financial_connections/account_ownership.rb +8 -0
- data/lib/stripe/resources/financial_connections/session.rb +20 -115
- data/lib/stripe/resources/financial_connections/transaction.rb +12 -57
- data/lib/stripe/resources/forwarding/request.rb +48 -93
- data/lib/stripe/resources/funding_instructions.rb +217 -24
- data/lib/stripe/resources/identity/verification_report.rb +165 -56
- data/lib/stripe/resources/identity/verification_session.rb +124 -247
- data/lib/stripe/resources/invoice.rb +500 -4017
- data/lib/stripe/resources/invoice_item.rb +69 -385
- data/lib/stripe/resources/invoice_line_item.rb +124 -251
- data/lib/stripe/resources/invoice_payment.rb +20 -47
- data/lib/stripe/resources/invoice_rendering_template.rb +8 -38
- data/lib/stripe/resources/issuing/authorization.rb +173 -836
- data/lib/stripe/resources/issuing/card.rb +98 -499
- data/lib/stripe/resources/issuing/cardholder.rb +108 -515
- data/lib/stripe/resources/issuing/dispute.rb +93 -620
- data/lib/stripe/resources/issuing/personalization_design.rb +32 -221
- data/lib/stripe/resources/issuing/physical_bundle.rb +13 -28
- data/lib/stripe/resources/issuing/token.rb +57 -60
- data/lib/stripe/resources/issuing/transaction.rb +147 -702
- data/lib/stripe/resources/line_item.rb +22 -35
- data/lib/stripe/resources/login_link.rb +8 -0
- data/lib/stripe/resources/mandate.rb +219 -94
- data/lib/stripe/resources/payment_intent.rb +1241 -13361
- data/lib/stripe/resources/payment_link.rb +333 -1357
- data/lib/stripe/resources/payment_method.rb +796 -966
- data/lib/stripe/resources/payment_method_configuration.rb +862 -2528
- data/lib/stripe/resources/payment_method_domain.rb +107 -63
- data/lib/stripe/resources/payout.rb +12 -150
- data/lib/stripe/resources/person.rb +184 -4
- data/lib/stripe/resources/plan.rb +20 -235
- data/lib/stripe/resources/price.rb +65 -509
- data/lib/stripe/resources/product.rb +23 -411
- data/lib/stripe/resources/product_feature.rb +8 -0
- data/lib/stripe/resources/promotion_code.rb +40 -182
- data/lib/stripe/resources/quote.rb +280 -2743
- data/lib/stripe/resources/radar/early_fraud_warning.rb +8 -51
- data/lib/stripe/resources/radar/value_list.rb +8 -92
- data/lib/stripe/resources/radar/value_list_item.rb +8 -68
- data/lib/stripe/resources/refund.rb +365 -159
- data/lib/stripe/resources/reporting/report_run.rb +12 -93
- data/lib/stripe/resources/reporting/report_type.rb +8 -8
- data/lib/stripe/resources/reserve_transaction.rb +8 -0
- data/lib/stripe/resources/reversal.rb +8 -0
- data/lib/stripe/resources/review.rb +20 -43
- data/lib/stripe/resources/setup_attempt.rb +284 -87
- data/lib/stripe/resources/setup_intent.rb +358 -4143
- data/lib/stripe/resources/shipping_rate.rb +44 -187
- data/lib/stripe/resources/sigma/scheduled_query_run.rb +13 -15
- data/lib/stripe/resources/source.rb +267 -611
- data/lib/stripe/resources/source_mandate_notification.rb +32 -0
- data/lib/stripe/resources/source_transaction.rb +54 -0
- data/lib/stripe/resources/subscription.rb +266 -1931
- data/lib/stripe/resources/subscription_item.rb +12 -379
- data/lib/stripe/resources/subscription_schedule.rb +230 -2273
- data/lib/stripe/resources/tax/calculation.rb +111 -220
- data/lib/stripe/resources/tax/calculation_line_item.rb +32 -0
- data/lib/stripe/resources/tax/registration.rb +1274 -2096
- data/lib/stripe/resources/tax/settings.rb +61 -64
- data/lib/stripe/resources/tax/transaction.rb +95 -122
- data/lib/stripe/resources/tax/transaction_line_item.rb +16 -0
- data/lib/stripe/resources/tax_code.rb +8 -17
- data/lib/stripe/resources/tax_deducted_at_source.rb +8 -0
- data/lib/stripe/resources/tax_id.rb +20 -75
- data/lib/stripe/resources/tax_rate.rb +12 -142
- data/lib/stripe/resources/terminal/configuration.rb +301 -1205
- data/lib/stripe/resources/terminal/connection_token.rb +8 -11
- data/lib/stripe/resources/terminal/location.rb +72 -126
- data/lib/stripe/resources/terminal/reader.rb +237 -509
- data/lib/stripe/resources/test_helpers/test_clock.rb +20 -43
- data/lib/stripe/resources/token.rb +8 -1191
- data/lib/stripe/resources/topup.rb +8 -132
- data/lib/stripe/resources/transfer.rb +8 -115
- data/lib/stripe/resources/treasury/credit_reversal.rb +12 -46
- data/lib/stripe/resources/treasury/debit_reversal.rb +20 -50
- data/lib/stripe/resources/treasury/financial_account.rb +55 -658
- data/lib/stripe/resources/treasury/financial_account_features.rb +192 -2
- data/lib/stripe/resources/treasury/inbound_transfer.rb +67 -115
- data/lib/stripe/resources/treasury/outbound_payment.rb +104 -334
- data/lib/stripe/resources/treasury/outbound_transfer.rb +93 -235
- data/lib/stripe/resources/treasury/received_credit.rb +76 -136
- data/lib/stripe/resources/treasury/received_debit.rb +68 -126
- data/lib/stripe/resources/treasury/transaction.rb +32 -82
- data/lib/stripe/resources/treasury/transaction_entry.rb +20 -74
- data/lib/stripe/resources/v2/billing/meter_event.rb +8 -0
- data/lib/stripe/resources/v2/billing/meter_event_adjustment.rb +16 -0
- data/lib/stripe/resources/v2/billing/meter_event_session.rb +8 -0
- data/lib/stripe/resources/v2/core/event.rb +67 -0
- data/lib/stripe/resources/v2/core/event_destination.rb +119 -0
- data/lib/stripe/resources/v2/core/event_notification.rb +62 -0
- data/lib/stripe/resources/v2/deleted_object.rb +21 -0
- data/lib/stripe/resources/webhook_endpoint.rb +8 -85
- data/lib/stripe/resources.rb +3 -110
- data/lib/stripe/services/account_capability_service.rb +0 -32
- data/lib/stripe/services/account_external_account_service.rb +0 -249
- data/lib/stripe/services/account_link_service.rb +0 -48
- data/lib/stripe/services/account_login_link_service.rb +0 -9
- data/lib/stripe/services/account_person_service.rb +0 -958
- data/lib/stripe/services/account_service.rb +0 -4710
- data/lib/stripe/services/account_session_service.rb +0 -862
- data/lib/stripe/services/apple_pay_domain_service.rb +0 -50
- data/lib/stripe/services/application_fee_refund_service.rb +0 -54
- data/lib/stripe/services/application_fee_service.rb +0 -57
- data/lib/stripe/services/apps/secret_service.rb +0 -116
- data/lib/stripe/services/balance_service.rb +0 -9
- data/lib/stripe/services/balance_settings_service.rb +0 -69
- data/lib/stripe/services/balance_transaction_service.rb +0 -69
- data/lib/stripe/services/billing/alert_service.rb +0 -113
- data/lib/stripe/services/billing/credit_balance_summary_service.rb +0 -51
- data/lib/stripe/services/billing/credit_balance_transaction_service.rb +0 -44
- data/lib/stripe/services/billing/credit_grant_service.rb +0 -174
- data/lib/stripe/services/billing/meter_event_adjustment_service.rb +0 -26
- data/lib/stripe/services/billing/meter_event_service.rb +0 -21
- data/lib/stripe/services/billing/meter_event_summary_service.rb +0 -39
- data/lib/stripe/services/billing/meter_service.rb +0 -130
- data/lib/stripe/services/billing_portal/configuration_service.rb +0 -486
- data/lib/stripe/services/billing_portal/session_service.rb +0 -177
- data/lib/stripe/services/billing_service.rb +1 -2
- data/lib/stripe/services/charge_service.rb +0 -1820
- data/lib/stripe/services/checkout/session_line_item_service.rb +0 -18
- data/lib/stripe/services/checkout/session_service.rb +0 -2882
- data/lib/stripe/services/climate/order_service.rb +0 -102
- data/lib/stripe/services/climate/product_service.rb +0 -27
- data/lib/stripe/services/climate/supplier_service.rb +0 -27
- data/lib/stripe/services/confirmation_token_service.rb +0 -9
- data/lib/stripe/services/country_spec_service.rb +0 -27
- data/lib/stripe/services/coupon_service.rb +0 -167
- data/lib/stripe/services/credit_note_line_item_service.rb +0 -18
- data/lib/stripe/services/credit_note_preview_lines_service.rb +0 -152
- data/lib/stripe/services/credit_note_service.rb +0 -369
- data/lib/stripe/services/customer_balance_transaction_service.rb +0 -63
- data/lib/stripe/services/customer_cash_balance_service.rb +0 -29
- data/lib/stripe/services/customer_cash_balance_transaction_service.rb +0 -27
- data/lib/stripe/services/customer_funding_instructions_service.rb +0 -42
- data/lib/stripe/services/customer_payment_method_service.rb +0 -40
- data/lib/stripe/services/customer_payment_source_service.rb +0 -179
- data/lib/stripe/services/customer_service.rb +0 -575
- data/lib/stripe/services/customer_session_service.rb +0 -99
- data/lib/stripe/services/customer_tax_id_service.rb +0 -44
- data/lib/stripe/services/dispute_service.rb +0 -374
- data/lib/stripe/services/entitlements/active_entitlement_service.rb +0 -36
- data/lib/stripe/services/entitlements/feature_service.rb +0 -76
- data/lib/stripe/services/ephemeral_key_service.rb +0 -36
- data/lib/stripe/services/event_service.rb +0 -65
- data/lib/stripe/services/exchange_rate_service.rb +4 -27
- data/lib/stripe/services/file_link_service.rb +0 -94
- data/lib/stripe/services/file_service.rb +0 -89
- data/lib/stripe/services/financial_connections/account_owner_service.rb +0 -27
- data/lib/stripe/services/financial_connections/account_service.rb +1 -102
- data/lib/stripe/services/financial_connections/session_service.rb +0 -100
- data/lib/stripe/services/financial_connections/transaction_service.rb +0 -70
- data/lib/stripe/services/financial_connections_service.rb +1 -2
- data/lib/stripe/services/forwarding/request_service.rb +0 -106
- data/lib/stripe/services/identity/verification_report_service.rb +0 -65
- data/lib/stripe/services/identity/verification_session_service.rb +0 -255
- data/lib/stripe/services/invoice_item_service.rb +0 -405
- data/lib/stripe/services/invoice_line_item_service.rb +0 -253
- data/lib/stripe/services/invoice_payment_service.rb +0 -58
- data/lib/stripe/services/invoice_rendering_template_service.rb +0 -51
- data/lib/stripe/services/invoice_service.rb +0 -3836
- data/lib/stripe/services/issuing/authorization_service.rb +0 -104
- data/lib/stripe/services/issuing/card_service.rb +0 -463
- data/lib/stripe/services/issuing/cardholder_service.rb +0 -526
- data/lib/stripe/services/issuing/dispute_service.rb +0 -633
- data/lib/stripe/services/issuing/personalization_design_service.rb +0 -193
- data/lib/stripe/services/issuing/physical_bundle_service.rb +0 -40
- data/lib/stripe/services/issuing/token_service.rb +0 -73
- data/lib/stripe/services/issuing/transaction_service.rb +0 -81
- data/lib/stripe/services/issuing_service.rb +1 -5
- data/lib/stripe/services/mandate_service.rb +0 -49
- data/lib/stripe/services/payment_intent_service.rb +0 -12747
- data/lib/stripe/services/payment_link_line_item_service.rb +0 -18
- data/lib/stripe/services/payment_link_service.rb +0 -1352
- data/lib/stripe/services/payment_method_configuration_service.rb +0 -2466
- data/lib/stripe/services/payment_method_domain_service.rb +0 -76
- data/lib/stripe/services/payment_method_service.rb +0 -881
- data/lib/stripe/services/payout_service.rb +0 -163
- data/lib/stripe/services/plan_service.rb +0 -248
- data/lib/stripe/services/price_service.rb +0 -512
- data/lib/stripe/services/product_feature_service.rb +0 -41
- data/lib/stripe/services/product_service.rb +0 -424
- data/lib/stripe/services/promotion_code_service.rb +1 -187
- data/lib/stripe/services/quote_computed_upfront_line_items_service.rb +0 -18
- data/lib/stripe/services/quote_line_item_service.rb +0 -18
- data/lib/stripe/services/quote_service.rb +1 -2344
- data/lib/stripe/services/radar/early_fraud_warning_service.rb +0 -61
- data/lib/stripe/services/radar/value_list_item_service.rb +0 -78
- data/lib/stripe/services/radar/value_list_service.rb +0 -102
- data/lib/stripe/services/refund_service.rb +0 -137
- data/lib/stripe/services/reporting/report_run_service.rb +0 -106
- data/lib/stripe/services/reporting/report_type_service.rb +0 -18
- data/lib/stripe/services/review_service.rb +0 -56
- data/lib/stripe/services/setup_attempt_service.rb +0 -51
- data/lib/stripe/services/setup_intent_service.rb +0 -3957
- data/lib/stripe/services/shipping_rate_service.rb +0 -200
- data/lib/stripe/services/sigma/scheduled_query_run_service.rb +0 -27
- data/lib/stripe/services/source_service.rb +0 -601
- data/lib/stripe/services/source_transaction_service.rb +0 -18
- data/lib/stripe/services/subscription_item_service.rb +0 -383
- data/lib/stripe/services/subscription_schedule_service.rb +0 -2196
- data/lib/stripe/services/subscription_service.rb +0 -1894
- data/lib/stripe/services/tax/calculation_line_item_service.rb +0 -18
- data/lib/stripe/services/tax/calculation_service.rb +0 -209
- data/lib/stripe/services/tax/registration_service.rb +0 -2063
- data/lib/stripe/services/tax/settings_service.rb +0 -74
- data/lib/stripe/services/tax/transaction_line_item_service.rb +0 -18
- data/lib/stripe/services/tax/transaction_service.rb +0 -111
- data/lib/stripe/services/tax_code_service.rb +0 -27
- data/lib/stripe/services/tax_id_service.rb +0 -84
- data/lib/stripe/services/tax_rate_service.rb +0 -155
- data/lib/stripe/services/tax_service.rb +1 -3
- data/lib/stripe/services/terminal/configuration_service.rb +0 -1212
- data/lib/stripe/services/terminal/connection_token_service.rb +0 -12
- data/lib/stripe/services/terminal/location_service.rb +0 -143
- data/lib/stripe/services/terminal/reader_service.rb +0 -427
- data/lib/stripe/services/terminal_service.rb +1 -3
- data/lib/stripe/services/test_helpers/confirmation_token_service.rb +0 -738
- data/lib/stripe/services/test_helpers/customer_service.rb +0 -18
- data/lib/stripe/services/test_helpers/issuing/authorization_service.rb +0 -745
- data/lib/stripe/services/test_helpers/issuing/card_service.rb +0 -45
- data/lib/stripe/services/test_helpers/issuing/personalization_design_service.rb +0 -41
- data/lib/stripe/services/test_helpers/issuing/transaction_service.rb +0 -632
- data/lib/stripe/services/test_helpers/refund_service.rb +0 -9
- data/lib/stripe/services/test_helpers/terminal/reader_service.rb +0 -87
- data/lib/stripe/services/test_helpers/test_clock_service.rb +0 -56
- data/lib/stripe/services/test_helpers/treasury/inbound_transfer_service.rb +0 -38
- data/lib/stripe/services/test_helpers/treasury/outbound_payment_service.rb +0 -87
- data/lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb +0 -87
- data/lib/stripe/services/test_helpers/treasury/received_credit_service.rb +0 -84
- data/lib/stripe/services/test_helpers/treasury/received_debit_service.rb +0 -84
- data/lib/stripe/services/token_service.rb +0 -1201
- data/lib/stripe/services/topup_service.rb +0 -142
- data/lib/stripe/services/transfer_reversal_service.rb +0 -66
- data/lib/stripe/services/transfer_service.rb +0 -123
- data/lib/stripe/services/treasury/credit_reversal_service.rb +0 -59
- data/lib/stripe/services/treasury/debit_reversal_service.rb +0 -63
- data/lib/stripe/services/treasury/financial_account_features_service.rb +0 -169
- data/lib/stripe/services/treasury/financial_account_service.rb +0 -502
- data/lib/stripe/services/treasury/inbound_transfer_service.rb +0 -88
- data/lib/stripe/services/treasury/outbound_payment_service.rb +0 -258
- data/lib/stripe/services/treasury/outbound_transfer_service.rb +0 -148
- data/lib/stripe/services/treasury/received_credit_service.rb +0 -52
- data/lib/stripe/services/treasury/received_debit_service.rb +0 -40
- data/lib/stripe/services/treasury/transaction_entry_service.rb +0 -87
- data/lib/stripe/services/treasury/transaction_service.rb +0 -95
- data/lib/stripe/services/v1_services.rb +1 -10
- data/lib/stripe/services/v2/billing/meter_event_adjustment_service.rb +0 -23
- data/lib/stripe/services/v2/billing/meter_event_service.rb +0 -25
- data/lib/stripe/services/v2/billing/meter_event_session_service.rb +0 -2
- data/lib/stripe/services/v2/billing/meter_event_stream_service.rb +0 -33
- data/lib/stripe/services/v2/core/event_destination_service.rb +0 -137
- data/lib/stripe/services/v2/core/event_service.rb +0 -16
- data/lib/stripe/services/v2/core_service.rb +1 -4
- data/lib/stripe/services/v2_services.rb +1 -4
- data/lib/stripe/services/webhook_endpoint_service.rb +0 -95
- data/lib/stripe/services.rb +0 -54
- data/lib/stripe/stripe_client.rb +8 -5
- data/lib/stripe/stripe_configuration.rb +2 -9
- data/lib/stripe/stripe_context.rb +68 -0
- data/lib/stripe/stripe_object.rb +34 -10
- data/lib/stripe/util.rb +25 -20
- data/lib/stripe/version.rb +1 -1
- data/lib/stripe.rb +3 -54
- data/rbi/stripe/resources/v2/core/event_notification.rbi +43 -0
- data/rbi/stripe/stripe_client.rbi +17 -0
- data/rbi/stripe.rbi +121931 -190301
- metadata +599 -189
- data/API_VERSION +0 -1
- data/CHANGELOG.md +0 -2780
- data/CODE_OF_CONDUCT.md +0 -77
- data/CONTRIBUTING.md +0 -25
- data/CONTRIBUTORS +0 -3
- data/Gemfile +0 -41
- data/History.txt +0 -1
- data/LICENSE +0 -21
- data/Makefile +0 -22
- data/OPENAPI_VERSION +0 -1
- data/README.md +0 -424
- data/Rakefile +0 -34
- data/VERSION +0 -1
- data/examples/README.md +0 -16
- data/examples/example_template.rb +0 -36
- data/examples/meter_event_stream.rb +0 -57
- data/examples/thinevent_webhook_handler.rb +0 -39
- data/justfile +0 -43
- data/lib/stripe/events/v2_core_account_closed_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_created_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_including_configuration_customer_capability_status_updated_event.rb +0 -23
- data/lib/stripe/events/v2_core_account_including_configuration_customer_updated_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_including_configuration_merchant_capability_status_updated_event.rb +0 -23
- data/lib/stripe/events/v2_core_account_including_configuration_merchant_updated_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_including_configuration_recipient_capability_status_updated_event.rb +0 -23
- data/lib/stripe/events/v2_core_account_including_configuration_recipient_updated_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_including_configuration_storer_capability_status_updated_event.rb +0 -23
- data/lib/stripe/events/v2_core_account_including_configuration_storer_updated_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_including_defaults_updated_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_including_identity_updated_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_including_requirements_updated_event.rb +0 -21
- data/lib/stripe/events/v2_core_account_link_returned_event.rb +0 -13
- data/lib/stripe/events/v2_core_account_person_created_event.rb +0 -23
- data/lib/stripe/events/v2_core_account_person_deleted_event.rb +0 -23
- data/lib/stripe/events/v2_core_account_person_updated_event.rb +0 -23
- data/lib/stripe/events/v2_core_account_updated_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_adjustment_created_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_financial_account_created_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_financial_account_updated_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_financial_address_activated_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_financial_address_failed_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_inbound_transfer_available_event.rb +0 -23
- data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_failed_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_processing_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_queued_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_returned_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_inbound_transfer_bank_debit_succeeded_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_payment_canceled_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_payment_created_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_payment_failed_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_payment_posted_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_payment_returned_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_payment_updated_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_transfer_canceled_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_transfer_created_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_transfer_failed_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_transfer_posted_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_transfer_returned_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_outbound_transfer_updated_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_payout_method_updated_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_credit_available_event.rb +0 -23
- data/lib/stripe/events/v2_money_management_received_credit_failed_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_credit_returned_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_credit_succeeded_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_debit_canceled_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_debit_failed_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_debit_pending_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_debit_succeeded_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_received_debit_updated_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_transaction_created_event.rb +0 -21
- data/lib/stripe/events/v2_money_management_transaction_updated_event.rb +0 -21
- data/lib/stripe/events/v2_payments_off_session_payment_authorization_attempt_failed_event.rb +0 -21
- data/lib/stripe/events/v2_payments_off_session_payment_authorization_attempt_started_event.rb +0 -22
- data/lib/stripe/events/v2_payments_off_session_payment_canceled_event.rb +0 -21
- data/lib/stripe/events/v2_payments_off_session_payment_created_event.rb +0 -21
- data/lib/stripe/events/v2_payments_off_session_payment_failed_event.rb +0 -21
- data/lib/stripe/events/v2_payments_off_session_payment_succeeded_event.rb +0 -21
- data/lib/stripe/resources/account_notice.rb +0 -123
- data/lib/stripe/resources/billing/meter_usage.rb +0 -23
- data/lib/stripe/resources/billing/meter_usage_row.rb +0 -28
- data/lib/stripe/resources/capital/financing_offer.rb +0 -179
- data/lib/stripe/resources/capital/financing_summary.rb +0 -55
- data/lib/stripe/resources/capital/financing_transaction.rb +0 -114
- data/lib/stripe/resources/financial_connections/account_inferred_balance.rb +0 -27
- data/lib/stripe/resources/financial_connections/institution.rb +0 -92
- data/lib/stripe/resources/fx_quote.rb +0 -186
- data/lib/stripe/resources/issuing/credit_underwriting_record.rb +0 -602
- data/lib/stripe/resources/issuing/dispute_settlement_detail.rb +0 -82
- data/lib/stripe/resources/issuing/fraud_liability_debit.rb +0 -86
- data/lib/stripe/resources/issuing/settlement.rb +0 -53
- data/lib/stripe/resources/margin.rb +0 -115
- data/lib/stripe/resources/order.rb +0 -2958
- data/lib/stripe/resources/payment_attempt_record.rb +0 -1181
- data/lib/stripe/resources/payment_intent_amount_details_line_item.rb +0 -72
- data/lib/stripe/resources/payment_record.rb +0 -1727
- data/lib/stripe/resources/privacy/redaction_job.rb +0 -298
- data/lib/stripe/resources/privacy/redaction_job_validation_error.rb +0 -33
- data/lib/stripe/resources/quote_line.rb +0 -274
- data/lib/stripe/resources/quote_preview_invoice.rb +0 -680
- data/lib/stripe/resources/quote_preview_subscription_schedule.rb +0 -395
- data/lib/stripe/resources/tax/association.rb +0 -66
- data/lib/stripe/resources/tax/form.rb +0 -211
- data/lib/stripe/resources/terminal/onboarding_link.rb +0 -84
- data/lib/stripe/resources/terminal/reader_collected_data.rb +0 -31
- data/lib/stripe/resources/v2/core/account.rb +0 -1938
- data/lib/stripe/resources/v2/core/account_link.rb +0 -72
- data/lib/stripe/resources/v2/core/person.rb +0 -276
- data/lib/stripe/resources/v2/core/vault/gb_bank_account.rb +0 -74
- data/lib/stripe/resources/v2/core/vault/us_bank_account.rb +0 -39
- data/lib/stripe/resources/v2/event.rb +0 -41
- data/lib/stripe/resources/v2/event_destination.rb +0 -73
- data/lib/stripe/resources/v2/financial_address_credit_simulation.rb +0 -20
- data/lib/stripe/resources/v2/financial_address_generated_microdeposits.rb +0 -22
- data/lib/stripe/resources/v2/money_management/adjustment.rb +0 -51
- data/lib/stripe/resources/v2/money_management/financial_account.rb +0 -79
- data/lib/stripe/resources/v2/money_management/financial_address.rb +0 -68
- data/lib/stripe/resources/v2/money_management/inbound_transfer.rb +0 -94
- data/lib/stripe/resources/v2/money_management/outbound_payment.rb +0 -129
- data/lib/stripe/resources/v2/money_management/outbound_payment_quote.rb +0 -82
- data/lib/stripe/resources/v2/money_management/outbound_setup_intent.rb +0 -45
- data/lib/stripe/resources/v2/money_management/outbound_transfer.rb +0 -117
- data/lib/stripe/resources/v2/money_management/payout_method.rb +0 -77
- data/lib/stripe/resources/v2/money_management/payout_methods_bank_account_spec.rb +0 -49
- data/lib/stripe/resources/v2/money_management/received_credit.rb +0 -122
- data/lib/stripe/resources/v2/money_management/received_debit.rb +0 -84
- data/lib/stripe/resources/v2/money_management/transaction.rb +0 -80
- data/lib/stripe/resources/v2/money_management/transaction_entry.rb +0 -70
- data/lib/stripe/resources/v2/payments/off_session_payment.rb +0 -89
- data/lib/stripe/services/account_notice_service.rb +0 -101
- data/lib/stripe/services/billing/meter_usage_service.rb +0 -76
- data/lib/stripe/services/capital/financing_offer_service.rb +0 -112
- data/lib/stripe/services/capital/financing_summary_service.rb +0 -28
- data/lib/stripe/services/capital/financing_transaction_service.rb +0 -79
- data/lib/stripe/services/capital_service.rb +0 -15
- data/lib/stripe/services/external_account_service.rb +0 -317
- data/lib/stripe/services/financial_connections/account_inferred_balance_service.rb +0 -37
- data/lib/stripe/services/financial_connections/institution_service.rb +0 -57
- data/lib/stripe/services/fx_quote_service.rb +0 -123
- data/lib/stripe/services/issuing/credit_underwriting_record_service.rb +0 -504
- data/lib/stripe/services/issuing/dispute_settlement_detail_service.rb +0 -66
- data/lib/stripe/services/issuing/fraud_liability_debit_service.rb +0 -83
- data/lib/stripe/services/margin_service.rb +0 -119
- data/lib/stripe/services/order_service.rb +0 -2388
- data/lib/stripe/services/payment_attempt_record_service.rb +0 -52
- data/lib/stripe/services/payment_record_service.rb +0 -562
- data/lib/stripe/services/privacy/redaction_job_service.rb +0 -240
- data/lib/stripe/services/privacy/redaction_job_validation_error_service.rb +0 -37
- data/lib/stripe/services/privacy_service.rb +0 -13
- data/lib/stripe/services/tax/association_service.rb +0 -31
- data/lib/stripe/services/tax/form_service.rb +0 -100
- data/lib/stripe/services/terminal/onboarding_link_service.rb +0 -56
- data/lib/stripe/services/terminal/reader_collected_data_service.rb +0 -28
- data/lib/stripe/services/v2/core/account_link_service.rb +0 -114
- data/lib/stripe/services/v2/core/account_service.rb +0 -4536
- data/lib/stripe/services/v2/core/accounts/person_service.rb +0 -1045
- data/lib/stripe/services/v2/core/vault/gb_bank_account_service.rb +0 -130
- data/lib/stripe/services/v2/core/vault/us_bank_account_service.rb +0 -107
- data/lib/stripe/services/v2/core/vault_service.rb +0 -18
- data/lib/stripe/services/v2/money_management/adjustment_service.rb +0 -74
- data/lib/stripe/services/v2/money_management/financial_account_service.rb +0 -119
- data/lib/stripe/services/v2/money_management/financial_address_service.rb +0 -82
- data/lib/stripe/services/v2/money_management/inbound_transfer_service.rb +0 -125
- data/lib/stripe/services/v2/money_management/outbound_payment_quote_service.rb +0 -95
- data/lib/stripe/services/v2/money_management/outbound_payment_service.rb +0 -199
- data/lib/stripe/services/v2/money_management/outbound_setup_intent_service.rb +0 -235
- data/lib/stripe/services/v2/money_management/outbound_transfer_service.rb +0 -172
- data/lib/stripe/services/v2/money_management/payout_method_service.rb +0 -90
- data/lib/stripe/services/v2/money_management/payout_methods_bank_account_spec_service.rb +0 -32
- data/lib/stripe/services/v2/money_management/received_credit_service.rb +0 -70
- data/lib/stripe/services/v2/money_management/received_debit_service.rb +0 -43
- data/lib/stripe/services/v2/money_management/transaction_entry_service.rb +0 -69
- data/lib/stripe/services/v2/money_management/transaction_service.rb +0 -73
- data/lib/stripe/services/v2/money_management_service.rb +0 -31
- data/lib/stripe/services/v2/payment_service.rb +0 -15
- data/lib/stripe/services/v2/payments/off_session_payment_service.rb +0 -152
- data/lib/stripe/services/v2/test_helper_service.rb +0 -15
- data/lib/stripe/services/v2/test_helpers/financial_address_service.rb +0 -53
- data/lib/stripe/thin_event.rb +0 -37
- data/stripe.gemspec +0 -47
@@ -7,7 +7,6 @@ module Stripe
|
|
7
7
|
class Quote < APIResource
|
8
8
|
extend Stripe::APIOperations::Create
|
9
9
|
extend Stripe::APIOperations::List
|
10
|
-
extend Stripe::APIOperations::NestedResource
|
11
10
|
include Stripe::APIOperations::Save
|
12
11
|
|
13
12
|
OBJECT_NAME = "quote"
|
@@ -15,15 +14,20 @@ module Stripe
|
|
15
14
|
"quote"
|
16
15
|
end
|
17
16
|
|
18
|
-
nested_resource_class_methods :preview_invoice, operations: %i[list]
|
19
|
-
nested_resource_class_methods :preview_subscription_schedule, operations: %i[list]
|
20
|
-
|
21
17
|
class AutomaticTax < Stripe::StripeObject
|
22
18
|
class Liability < Stripe::StripeObject
|
23
19
|
# The connected account being referenced when `type` is `account`.
|
24
20
|
attr_reader :account
|
25
21
|
# Type of the account referenced.
|
26
22
|
attr_reader :type
|
23
|
+
|
24
|
+
def self.inner_class_types
|
25
|
+
@inner_class_types = {}
|
26
|
+
end
|
27
|
+
|
28
|
+
def self.field_remappings
|
29
|
+
@field_remappings = {}
|
30
|
+
end
|
27
31
|
end
|
28
32
|
# Automatically calculate taxes
|
29
33
|
attr_reader :enabled
|
@@ -33,24 +37,17 @@ module Stripe
|
|
33
37
|
attr_reader :provider
|
34
38
|
# The status of the most recent automated tax calculation for this quote.
|
35
39
|
attr_reader :status
|
36
|
-
end
|
37
40
|
|
38
|
-
|
39
|
-
|
40
|
-
class Failed < Stripe::StripeObject
|
41
|
-
# The failure `code` is more granular than the `reason` provided and may correspond to a Stripe error code. For automation errors, this field is one of: `reverse_api_failure`, `reverse_api_deadline_exceeeded`, or `reverse_api_response_validation_error`, which are Stripe error codes and map to the error `message` field.
|
42
|
-
attr_reader :failure_code
|
43
|
-
# Information derived from the `failure_code` or a freeform message that explains the error as a human-readable English string. For example, "margin ID is not a valid ID".
|
44
|
-
attr_reader :message
|
45
|
-
# The reason the reestimation failed.
|
46
|
-
attr_reader :reason
|
47
|
-
end
|
48
|
-
# When `status` is `failed`, provides details about the quote reestimation failure.
|
49
|
-
attr_reader :failed
|
50
|
-
# Latest status of the reestimation.
|
51
|
-
attr_reader :status
|
41
|
+
def self.inner_class_types
|
42
|
+
@inner_class_types = { liability: Liability }
|
52
43
|
end
|
53
44
|
|
45
|
+
def self.field_remappings
|
46
|
+
@field_remappings = {}
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
class Computed < Stripe::StripeObject
|
54
51
|
class Recurring < Stripe::StripeObject
|
55
52
|
class TotalDetails < Stripe::StripeObject
|
56
53
|
class Breakdown < Stripe::StripeObject
|
@@ -62,6 +59,14 @@ module Stripe
|
|
62
59
|
#
|
63
60
|
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
|
64
61
|
attr_reader :discount
|
62
|
+
|
63
|
+
def self.inner_class_types
|
64
|
+
@inner_class_types = {}
|
65
|
+
end
|
66
|
+
|
67
|
+
def self.field_remappings
|
68
|
+
@field_remappings = {}
|
69
|
+
end
|
65
70
|
end
|
66
71
|
|
67
72
|
class Tax < Stripe::StripeObject
|
@@ -75,11 +80,27 @@ module Stripe
|
|
75
80
|
attr_reader :taxability_reason
|
76
81
|
# The amount on which tax is calculated, in cents (or local equivalent).
|
77
82
|
attr_reader :taxable_amount
|
83
|
+
|
84
|
+
def self.inner_class_types
|
85
|
+
@inner_class_types = {}
|
86
|
+
end
|
87
|
+
|
88
|
+
def self.field_remappings
|
89
|
+
@field_remappings = {}
|
90
|
+
end
|
78
91
|
end
|
79
92
|
# The aggregated discounts.
|
80
93
|
attr_reader :discounts
|
81
94
|
# The aggregated tax amounts by rate.
|
82
95
|
attr_reader :taxes
|
96
|
+
|
97
|
+
def self.inner_class_types
|
98
|
+
@inner_class_types = { discounts: Discount, taxes: Tax }
|
99
|
+
end
|
100
|
+
|
101
|
+
def self.field_remappings
|
102
|
+
@field_remappings = {}
|
103
|
+
end
|
83
104
|
end
|
84
105
|
# This is the sum of all the discounts.
|
85
106
|
attr_reader :amount_discount
|
@@ -89,6 +110,14 @@ module Stripe
|
|
89
110
|
attr_reader :amount_tax
|
90
111
|
# Attribute for field breakdown
|
91
112
|
attr_reader :breakdown
|
113
|
+
|
114
|
+
def self.inner_class_types
|
115
|
+
@inner_class_types = { breakdown: Breakdown }
|
116
|
+
end
|
117
|
+
|
118
|
+
def self.field_remappings
|
119
|
+
@field_remappings = {}
|
120
|
+
end
|
92
121
|
end
|
93
122
|
# Total before any discounts or taxes are applied.
|
94
123
|
attr_reader :amount_subtotal
|
@@ -100,6 +129,14 @@ module Stripe
|
|
100
129
|
attr_reader :interval_count
|
101
130
|
# Attribute for field total_details
|
102
131
|
attr_reader :total_details
|
132
|
+
|
133
|
+
def self.inner_class_types
|
134
|
+
@inner_class_types = { total_details: TotalDetails }
|
135
|
+
end
|
136
|
+
|
137
|
+
def self.field_remappings
|
138
|
+
@field_remappings = {}
|
139
|
+
end
|
103
140
|
end
|
104
141
|
|
105
142
|
class Upfront < Stripe::StripeObject
|
@@ -113,6 +150,14 @@ module Stripe
|
|
113
150
|
#
|
114
151
|
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
|
115
152
|
attr_reader :discount
|
153
|
+
|
154
|
+
def self.inner_class_types
|
155
|
+
@inner_class_types = {}
|
156
|
+
end
|
157
|
+
|
158
|
+
def self.field_remappings
|
159
|
+
@field_remappings = {}
|
160
|
+
end
|
116
161
|
end
|
117
162
|
|
118
163
|
class Tax < Stripe::StripeObject
|
@@ -126,2686 +171,271 @@ module Stripe
|
|
126
171
|
attr_reader :taxability_reason
|
127
172
|
# The amount on which tax is calculated, in cents (or local equivalent).
|
128
173
|
attr_reader :taxable_amount
|
129
|
-
end
|
130
|
-
# The aggregated discounts.
|
131
|
-
attr_reader :discounts
|
132
|
-
# The aggregated tax amounts by rate.
|
133
|
-
attr_reader :taxes
|
134
|
-
end
|
135
|
-
# This is the sum of all the discounts.
|
136
|
-
attr_reader :amount_discount
|
137
|
-
# This is the sum of all the shipping amounts.
|
138
|
-
attr_reader :amount_shipping
|
139
|
-
# This is the sum of all the tax amounts.
|
140
|
-
attr_reader :amount_tax
|
141
|
-
# Attribute for field breakdown
|
142
|
-
attr_reader :breakdown
|
143
|
-
end
|
144
|
-
# Total before any discounts or taxes are applied.
|
145
|
-
attr_reader :amount_subtotal
|
146
|
-
# Total after discounts and taxes are applied.
|
147
|
-
attr_reader :amount_total
|
148
|
-
# The line items that will appear on the next invoice after this quote is accepted. This does not include pending invoice items that exist on the customer but may still be included in the next invoice.
|
149
|
-
attr_reader :line_items
|
150
|
-
# Attribute for field total_details
|
151
|
-
attr_reader :total_details
|
152
|
-
end
|
153
|
-
# Details of the most recent reestimate of the quote's preview schedules and upcoming invoices, including the status of Stripe's calculation.
|
154
|
-
attr_reader :last_reestimation_details
|
155
|
-
# The definitive totals and line items the customer will be charged on a recurring basis. Takes into account the line items with recurring prices and discounts with `duration=forever` coupons only. Defaults to `null` if no inputted line items with recurring prices.
|
156
|
-
attr_reader :recurring
|
157
|
-
# The time at which the quote's estimated schedules and upcoming invoices were generated.
|
158
|
-
attr_reader :updated_at
|
159
|
-
# Attribute for field upfront
|
160
|
-
attr_reader :upfront
|
161
|
-
end
|
162
|
-
|
163
|
-
class FromQuote < Stripe::StripeObject
|
164
|
-
# Whether this quote is a revision of a different quote.
|
165
|
-
attr_reader :is_revision
|
166
|
-
# The quote that was cloned.
|
167
|
-
attr_reader :quote
|
168
|
-
end
|
169
|
-
|
170
|
-
class InvoiceSettings < Stripe::StripeObject
|
171
|
-
class Issuer < Stripe::StripeObject
|
172
|
-
# The connected account being referenced when `type` is `account`.
|
173
|
-
attr_reader :account
|
174
|
-
# Type of the account referenced.
|
175
|
-
attr_reader :type
|
176
|
-
end
|
177
|
-
# Number of days within which a customer must pay invoices generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
|
178
|
-
attr_reader :days_until_due
|
179
|
-
# Attribute for field issuer
|
180
|
-
attr_reader :issuer
|
181
|
-
end
|
182
|
-
|
183
|
-
class StatusDetails < Stripe::StripeObject
|
184
|
-
class Canceled < Stripe::StripeObject
|
185
|
-
# The reason this quote was marked as canceled.
|
186
|
-
attr_reader :reason
|
187
|
-
# Time at which the quote was marked as canceled. Measured in seconds since the Unix epoch.
|
188
|
-
attr_reader :transitioned_at
|
189
|
-
end
|
190
|
-
|
191
|
-
class Stale < Stripe::StripeObject
|
192
|
-
class LastReason < Stripe::StripeObject
|
193
|
-
class LinesInvalid < Stripe::StripeObject
|
194
|
-
# The timestamp at which the lines were marked as invalid.
|
195
|
-
attr_reader :invalid_at
|
196
|
-
# The list of lines that became invalid at the given timestamp.
|
197
|
-
attr_reader :lines
|
198
|
-
end
|
199
|
-
|
200
|
-
class SubscriptionChanged < Stripe::StripeObject
|
201
|
-
# The subscription's state before the quote was marked as stale.
|
202
|
-
attr_reader :previous_subscription
|
203
|
-
end
|
204
|
-
|
205
|
-
class SubscriptionScheduleChanged < Stripe::StripeObject
|
206
|
-
# The subscription schedule's state before the quote was marked as stale.
|
207
|
-
attr_reader :previous_subscription_schedule
|
208
|
-
end
|
209
|
-
# The ID of the line that is invalid if the stale reason type is `line_invalid`.
|
210
|
-
attr_reader :line_invalid
|
211
|
-
# The IDs of the lines that are invalid if the stale reason type is `lines_invalid`.
|
212
|
-
attr_reader :lines_invalid
|
213
|
-
# The user supplied mark stale reason.
|
214
|
-
attr_reader :marked_stale
|
215
|
-
# The ID of the subscription that was canceled.
|
216
|
-
attr_reader :subscription_canceled
|
217
|
-
# Attribute for field subscription_changed
|
218
|
-
attr_reader :subscription_changed
|
219
|
-
# The ID of the subscription that was expired.
|
220
|
-
attr_reader :subscription_expired
|
221
|
-
# The ID of the subscription schedule that was canceled.
|
222
|
-
attr_reader :subscription_schedule_canceled
|
223
|
-
# Attribute for field subscription_schedule_changed
|
224
|
-
attr_reader :subscription_schedule_changed
|
225
|
-
# The ID of the subscription schedule that was released.
|
226
|
-
attr_reader :subscription_schedule_released
|
227
|
-
# The reason the quote was marked as stale.
|
228
|
-
attr_reader :type
|
229
|
-
end
|
230
|
-
# Time at which the quote expires. Measured in seconds since the Unix epoch.
|
231
|
-
attr_reader :expires_at
|
232
|
-
# The most recent reason this quote was marked as stale.
|
233
|
-
attr_reader :last_reason
|
234
|
-
# Time at which the stale reason was updated. Measured in seconds since the Unix epoch.
|
235
|
-
attr_reader :last_updated_at
|
236
|
-
# Time at which the quote was marked as stale. Measured in seconds since the Unix epoch.
|
237
|
-
attr_reader :transitioned_at
|
238
|
-
end
|
239
|
-
# Attribute for field canceled
|
240
|
-
attr_reader :canceled
|
241
|
-
# Attribute for field stale
|
242
|
-
attr_reader :stale
|
243
|
-
end
|
244
|
-
|
245
|
-
class StatusTransitions < Stripe::StripeObject
|
246
|
-
# The time that the quote was accepted. Measured in seconds since Unix epoch.
|
247
|
-
attr_reader :accepted_at
|
248
|
-
# The time that the quote was canceled. Measured in seconds since Unix epoch.
|
249
|
-
attr_reader :canceled_at
|
250
|
-
# The time that the quote was finalized. Measured in seconds since Unix epoch.
|
251
|
-
attr_reader :finalized_at
|
252
|
-
end
|
253
|
-
|
254
|
-
class SubscriptionData < Stripe::StripeObject
|
255
|
-
class BillOnAcceptance < Stripe::StripeObject
|
256
|
-
class BillFrom < Stripe::StripeObject
|
257
|
-
class LineStartsAt < Stripe::StripeObject
|
258
|
-
# Unique identifier for the object.
|
259
|
-
attr_reader :id
|
260
|
-
end
|
261
|
-
# The materialized time.
|
262
|
-
attr_reader :computed
|
263
|
-
# The timestamp the given line starts at.
|
264
|
-
attr_reader :line_starts_at
|
265
|
-
# A precise Unix timestamp.
|
266
|
-
attr_reader :timestamp
|
267
|
-
# The type of method to specify the `bill_from` time.
|
268
|
-
attr_reader :type
|
269
|
-
end
|
270
|
-
|
271
|
-
class BillUntil < Stripe::StripeObject
|
272
|
-
class Duration < Stripe::StripeObject
|
273
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
274
|
-
attr_reader :interval
|
275
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
276
|
-
attr_reader :interval_count
|
277
|
-
end
|
278
|
-
|
279
|
-
class LineEndsAt < Stripe::StripeObject
|
280
|
-
# Unique identifier for the object.
|
281
|
-
attr_reader :id
|
282
|
-
end
|
283
|
-
# The materialized time.
|
284
|
-
attr_reader :computed
|
285
|
-
# Time span for the quote line starting from the `starts_at` date.
|
286
|
-
attr_reader :duration
|
287
|
-
# The timestamp the given line ends at.
|
288
|
-
attr_reader :line_ends_at
|
289
|
-
# A precise Unix timestamp.
|
290
|
-
attr_reader :timestamp
|
291
|
-
# The type of method to specify the `bill_until` time.
|
292
|
-
attr_reader :type
|
293
|
-
end
|
294
|
-
# The start of the period to bill from when the Quote is accepted.
|
295
|
-
attr_reader :bill_from
|
296
|
-
# The end of the period to bill until when the Quote is accepted.
|
297
|
-
attr_reader :bill_until
|
298
|
-
end
|
299
174
|
|
300
|
-
|
301
|
-
|
302
|
-
attr_reader :type
|
303
|
-
end
|
304
|
-
|
305
|
-
class Prebilling < Stripe::StripeObject
|
306
|
-
# Attribute for field iterations
|
307
|
-
attr_reader :iterations
|
308
|
-
end
|
309
|
-
# Describes the period to bill for upon accepting the quote.
|
310
|
-
attr_reader :bill_on_acceptance
|
311
|
-
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
312
|
-
attr_reader :billing_behavior
|
313
|
-
# Whether the subscription will always start a new billing period when the quote is accepted.
|
314
|
-
attr_reader :billing_cycle_anchor
|
315
|
-
# The billing mode of the quote.
|
316
|
-
attr_reader :billing_mode
|
317
|
-
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
|
318
|
-
attr_reader :description
|
319
|
-
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. This date is ignored if it is in the past when the quote is accepted. Measured in seconds since the Unix epoch.
|
320
|
-
attr_reader :effective_date
|
321
|
-
# Behavior of the subscription schedule and underlying subscription when it ends.
|
322
|
-
attr_reader :end_behavior
|
323
|
-
# The id of the subscription that will be updated when the quote is accepted.
|
324
|
-
attr_reader :from_subscription
|
325
|
-
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
|
326
|
-
attr_reader :metadata
|
327
|
-
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
|
328
|
-
attr_reader :prebilling
|
329
|
-
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the quote is accepted.
|
330
|
-
attr_reader :proration_behavior
|
331
|
-
# Integer representing the number of trial period days before the customer is charged for the first time.
|
332
|
-
attr_reader :trial_period_days
|
333
|
-
end
|
334
|
-
|
335
|
-
class SubscriptionDataOverride < Stripe::StripeObject
|
336
|
-
class AppliesTo < Stripe::StripeObject
|
337
|
-
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
|
338
|
-
attr_reader :new_reference
|
339
|
-
# The ID of the schedule the line applies to.
|
340
|
-
attr_reader :subscription_schedule
|
341
|
-
# Describes whether the quote line is affecting a new schedule or an existing schedule.
|
342
|
-
attr_reader :type
|
343
|
-
end
|
344
|
-
|
345
|
-
class BillOnAcceptance < Stripe::StripeObject
|
346
|
-
class BillFrom < Stripe::StripeObject
|
347
|
-
class LineStartsAt < Stripe::StripeObject
|
348
|
-
# Unique identifier for the object.
|
349
|
-
attr_reader :id
|
350
|
-
end
|
351
|
-
# The materialized time.
|
352
|
-
attr_reader :computed
|
353
|
-
# The timestamp the given line starts at.
|
354
|
-
attr_reader :line_starts_at
|
355
|
-
# A precise Unix timestamp.
|
356
|
-
attr_reader :timestamp
|
357
|
-
# The type of method to specify the `bill_from` time.
|
358
|
-
attr_reader :type
|
359
|
-
end
|
360
|
-
|
361
|
-
class BillUntil < Stripe::StripeObject
|
362
|
-
class Duration < Stripe::StripeObject
|
363
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
364
|
-
attr_reader :interval
|
365
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
366
|
-
attr_reader :interval_count
|
367
|
-
end
|
368
|
-
|
369
|
-
class LineEndsAt < Stripe::StripeObject
|
370
|
-
# Unique identifier for the object.
|
371
|
-
attr_reader :id
|
372
|
-
end
|
373
|
-
# The materialized time.
|
374
|
-
attr_reader :computed
|
375
|
-
# Time span for the quote line starting from the `starts_at` date.
|
376
|
-
attr_reader :duration
|
377
|
-
# The timestamp the given line ends at.
|
378
|
-
attr_reader :line_ends_at
|
379
|
-
# A precise Unix timestamp.
|
380
|
-
attr_reader :timestamp
|
381
|
-
# The type of method to specify the `bill_until` time.
|
382
|
-
attr_reader :type
|
383
|
-
end
|
384
|
-
# The start of the period to bill from when the Quote is accepted.
|
385
|
-
attr_reader :bill_from
|
386
|
-
# The end of the period to bill until when the Quote is accepted.
|
387
|
-
attr_reader :bill_until
|
388
|
-
end
|
389
|
-
# Attribute for field applies_to
|
390
|
-
attr_reader :applies_to
|
391
|
-
# Describes the period to bill for upon accepting the quote.
|
392
|
-
attr_reader :bill_on_acceptance
|
393
|
-
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
394
|
-
attr_reader :billing_behavior
|
395
|
-
# The customer which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
|
396
|
-
attr_reader :customer
|
397
|
-
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
|
398
|
-
attr_reader :description
|
399
|
-
# Behavior of the subscription schedule and underlying subscription when it ends.
|
400
|
-
attr_reader :end_behavior
|
401
|
-
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the quote is accepted.
|
402
|
-
attr_reader :proration_behavior
|
403
|
-
end
|
404
|
-
|
405
|
-
class SubscriptionSchedule < Stripe::StripeObject
|
406
|
-
class AppliesTo < Stripe::StripeObject
|
407
|
-
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
|
408
|
-
attr_reader :new_reference
|
409
|
-
# The ID of the schedule the line applies to.
|
410
|
-
attr_reader :subscription_schedule
|
411
|
-
# Describes whether the quote line is affecting a new schedule or an existing schedule.
|
412
|
-
attr_reader :type
|
413
|
-
end
|
414
|
-
# Attribute for field applies_to
|
415
|
-
attr_reader :applies_to
|
416
|
-
# The subscription schedule that was created or updated from this quote.
|
417
|
-
attr_reader :subscription_schedule
|
418
|
-
end
|
419
|
-
|
420
|
-
class TotalDetails < Stripe::StripeObject
|
421
|
-
class Breakdown < Stripe::StripeObject
|
422
|
-
class Discount < Stripe::StripeObject
|
423
|
-
# The amount discounted.
|
424
|
-
attr_reader :amount
|
425
|
-
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
|
426
|
-
# It contains information about when the discount began, when it will end, and what it is applied to.
|
427
|
-
#
|
428
|
-
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
|
429
|
-
attr_reader :discount
|
430
|
-
end
|
431
|
-
|
432
|
-
class Tax < Stripe::StripeObject
|
433
|
-
# Amount of tax applied for this rate.
|
434
|
-
attr_reader :amount
|
435
|
-
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
|
436
|
-
#
|
437
|
-
# Related guide: [Tax rates](/billing/taxes/tax-rates)
|
438
|
-
attr_reader :rate
|
439
|
-
# The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.
|
440
|
-
attr_reader :taxability_reason
|
441
|
-
# The amount on which tax is calculated, in cents (or local equivalent).
|
442
|
-
attr_reader :taxable_amount
|
443
|
-
end
|
444
|
-
# The aggregated discounts.
|
445
|
-
attr_reader :discounts
|
446
|
-
# The aggregated tax amounts by rate.
|
447
|
-
attr_reader :taxes
|
448
|
-
end
|
449
|
-
# This is the sum of all the discounts.
|
450
|
-
attr_reader :amount_discount
|
451
|
-
# This is the sum of all the shipping amounts.
|
452
|
-
attr_reader :amount_shipping
|
453
|
-
# This is the sum of all the tax amounts.
|
454
|
-
attr_reader :amount_tax
|
455
|
-
# Attribute for field breakdown
|
456
|
-
attr_reader :breakdown
|
457
|
-
end
|
458
|
-
|
459
|
-
class TransferData < Stripe::StripeObject
|
460
|
-
# The amount in cents (or local equivalent) that will be transferred to the destination account when the invoice is paid. By default, the entire amount is transferred to the destination.
|
461
|
-
attr_reader :amount
|
462
|
-
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount will be transferred to the destination.
|
463
|
-
attr_reader :amount_percent
|
464
|
-
# The account where funds from the payment will be transferred to upon payment success.
|
465
|
-
attr_reader :destination
|
466
|
-
end
|
467
|
-
|
468
|
-
class ListParams < Stripe::RequestParams
|
469
|
-
# The ID of the customer whose quotes will be retrieved.
|
470
|
-
attr_accessor :customer
|
471
|
-
# The ID of the account whose quotes will be retrieved.
|
472
|
-
attr_accessor :customer_account
|
473
|
-
# 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.
|
474
|
-
attr_accessor :ending_before
|
475
|
-
# Specifies which fields in the response should be expanded.
|
476
|
-
attr_accessor :expand
|
477
|
-
# The subscription which the quote updates.
|
478
|
-
attr_accessor :from_subscription
|
479
|
-
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
480
|
-
attr_accessor :limit
|
481
|
-
# 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.
|
482
|
-
attr_accessor :starting_after
|
483
|
-
# The status of the quote.
|
484
|
-
attr_accessor :status
|
485
|
-
# Provides a list of quotes that are associated with the specified test clock. The response will not include quotes with test clocks if this and the customer parameter is not set.
|
486
|
-
attr_accessor :test_clock
|
487
|
-
|
488
|
-
def initialize(
|
489
|
-
customer: nil,
|
490
|
-
customer_account: nil,
|
491
|
-
ending_before: nil,
|
492
|
-
expand: nil,
|
493
|
-
from_subscription: nil,
|
494
|
-
limit: nil,
|
495
|
-
starting_after: nil,
|
496
|
-
status: nil,
|
497
|
-
test_clock: nil
|
498
|
-
)
|
499
|
-
@customer = customer
|
500
|
-
@customer_account = customer_account
|
501
|
-
@ending_before = ending_before
|
502
|
-
@expand = expand
|
503
|
-
@from_subscription = from_subscription
|
504
|
-
@limit = limit
|
505
|
-
@starting_after = starting_after
|
506
|
-
@status = status
|
507
|
-
@test_clock = test_clock
|
508
|
-
end
|
509
|
-
end
|
510
|
-
|
511
|
-
class CreateParams < Stripe::RequestParams
|
512
|
-
class AutomaticTax < Stripe::RequestParams
|
513
|
-
class Liability < Stripe::RequestParams
|
514
|
-
# The connected account being referenced when `type` is `account`.
|
515
|
-
attr_accessor :account
|
516
|
-
# Type of the account referenced in the request.
|
517
|
-
attr_accessor :type
|
518
|
-
|
519
|
-
def initialize(account: nil, type: nil)
|
520
|
-
@account = account
|
521
|
-
@type = type
|
522
|
-
end
|
523
|
-
end
|
524
|
-
# Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
|
525
|
-
attr_accessor :enabled
|
526
|
-
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
|
527
|
-
attr_accessor :liability
|
528
|
-
|
529
|
-
def initialize(enabled: nil, liability: nil)
|
530
|
-
@enabled = enabled
|
531
|
-
@liability = liability
|
532
|
-
end
|
533
|
-
end
|
534
|
-
|
535
|
-
class Discount < Stripe::RequestParams
|
536
|
-
class DiscountEnd < Stripe::RequestParams
|
537
|
-
class Duration < Stripe::RequestParams
|
538
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
539
|
-
attr_accessor :interval
|
540
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
541
|
-
attr_accessor :interval_count
|
542
|
-
|
543
|
-
def initialize(interval: nil, interval_count: nil)
|
544
|
-
@interval = interval
|
545
|
-
@interval_count = interval_count
|
546
|
-
end
|
547
|
-
end
|
548
|
-
# Time span for the redeemed discount.
|
549
|
-
attr_accessor :duration
|
550
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
551
|
-
attr_accessor :timestamp
|
552
|
-
# The type of calculation made to determine when the discount ends.
|
553
|
-
attr_accessor :type
|
554
|
-
|
555
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
556
|
-
@duration = duration
|
557
|
-
@timestamp = timestamp
|
558
|
-
@type = type
|
559
|
-
end
|
560
|
-
end
|
561
|
-
# ID of the coupon to create a new discount for.
|
562
|
-
attr_accessor :coupon
|
563
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
564
|
-
attr_accessor :discount
|
565
|
-
# Details to determine how long the discount should be applied for.
|
566
|
-
attr_accessor :discount_end
|
567
|
-
# ID of the promotion code to create a new discount for.
|
568
|
-
attr_accessor :promotion_code
|
569
|
-
|
570
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
571
|
-
@coupon = coupon
|
572
|
-
@discount = discount
|
573
|
-
@discount_end = discount_end
|
574
|
-
@promotion_code = promotion_code
|
575
|
-
end
|
576
|
-
end
|
577
|
-
|
578
|
-
class FromQuote < Stripe::RequestParams
|
579
|
-
# Whether this quote is a revision of the previous quote.
|
580
|
-
attr_accessor :is_revision
|
581
|
-
# The `id` of the quote that will be cloned.
|
582
|
-
attr_accessor :quote
|
583
|
-
|
584
|
-
def initialize(is_revision: nil, quote: nil)
|
585
|
-
@is_revision = is_revision
|
586
|
-
@quote = quote
|
587
|
-
end
|
588
|
-
end
|
589
|
-
|
590
|
-
class InvoiceSettings < Stripe::RequestParams
|
591
|
-
class Issuer < Stripe::RequestParams
|
592
|
-
# The connected account being referenced when `type` is `account`.
|
593
|
-
attr_accessor :account
|
594
|
-
# Type of the account referenced in the request.
|
595
|
-
attr_accessor :type
|
596
|
-
|
597
|
-
def initialize(account: nil, type: nil)
|
598
|
-
@account = account
|
599
|
-
@type = type
|
600
|
-
end
|
601
|
-
end
|
602
|
-
# Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
|
603
|
-
attr_accessor :days_until_due
|
604
|
-
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
|
605
|
-
attr_accessor :issuer
|
606
|
-
|
607
|
-
def initialize(days_until_due: nil, issuer: nil)
|
608
|
-
@days_until_due = days_until_due
|
609
|
-
@issuer = issuer
|
610
|
-
end
|
611
|
-
end
|
612
|
-
|
613
|
-
class Line < Stripe::RequestParams
|
614
|
-
class Action < Stripe::RequestParams
|
615
|
-
class AddDiscount < Stripe::RequestParams
|
616
|
-
class DiscountEnd < Stripe::RequestParams
|
617
|
-
# The type of calculation made to determine when the discount ends.
|
618
|
-
attr_accessor :type
|
619
|
-
|
620
|
-
def initialize(type: nil)
|
621
|
-
@type = type
|
175
|
+
def self.inner_class_types
|
176
|
+
@inner_class_types = {}
|
622
177
|
end
|
623
|
-
end
|
624
|
-
# The coupon code to redeem.
|
625
|
-
attr_accessor :coupon
|
626
|
-
# An ID of an existing discount for a coupon that was already redeemed.
|
627
|
-
attr_accessor :discount
|
628
|
-
# Details to determine how long the discount should be applied for.
|
629
|
-
attr_accessor :discount_end
|
630
|
-
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
|
631
|
-
attr_accessor :index
|
632
|
-
# The promotion code to redeem.
|
633
|
-
attr_accessor :promotion_code
|
634
|
-
|
635
|
-
def initialize(
|
636
|
-
coupon: nil,
|
637
|
-
discount: nil,
|
638
|
-
discount_end: nil,
|
639
|
-
index: nil,
|
640
|
-
promotion_code: nil
|
641
|
-
)
|
642
|
-
@coupon = coupon
|
643
|
-
@discount = discount
|
644
|
-
@discount_end = discount_end
|
645
|
-
@index = index
|
646
|
-
@promotion_code = promotion_code
|
647
|
-
end
|
648
|
-
end
|
649
|
-
|
650
|
-
class AddItem < Stripe::RequestParams
|
651
|
-
class Discount < Stripe::RequestParams
|
652
|
-
class DiscountEnd < Stripe::RequestParams
|
653
|
-
class Duration < Stripe::RequestParams
|
654
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
655
|
-
attr_accessor :interval
|
656
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
657
|
-
attr_accessor :interval_count
|
658
|
-
|
659
|
-
def initialize(interval: nil, interval_count: nil)
|
660
|
-
@interval = interval
|
661
|
-
@interval_count = interval_count
|
662
|
-
end
|
663
|
-
end
|
664
|
-
# Time span for the redeemed discount.
|
665
|
-
attr_accessor :duration
|
666
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
667
|
-
attr_accessor :timestamp
|
668
|
-
# The type of calculation made to determine when the discount ends.
|
669
|
-
attr_accessor :type
|
670
|
-
|
671
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
672
|
-
@duration = duration
|
673
|
-
@timestamp = timestamp
|
674
|
-
@type = type
|
675
|
-
end
|
676
|
-
end
|
677
|
-
# ID of the coupon to create a new discount for.
|
678
|
-
attr_accessor :coupon
|
679
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
680
|
-
attr_accessor :discount
|
681
|
-
# Details to determine how long the discount should be applied for.
|
682
|
-
attr_accessor :discount_end
|
683
|
-
# ID of the promotion code to create a new discount for.
|
684
|
-
attr_accessor :promotion_code
|
685
|
-
|
686
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
687
|
-
@coupon = coupon
|
688
|
-
@discount = discount
|
689
|
-
@discount_end = discount_end
|
690
|
-
@promotion_code = promotion_code
|
691
|
-
end
|
692
|
-
end
|
693
|
-
|
694
|
-
class Trial < Stripe::RequestParams
|
695
|
-
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
696
|
-
attr_accessor :converts_to
|
697
|
-
# Determines the type of trial for this item.
|
698
|
-
attr_accessor :type
|
699
|
-
|
700
|
-
def initialize(converts_to: nil, type: nil)
|
701
|
-
@converts_to = converts_to
|
702
|
-
@type = type
|
703
|
-
end
|
704
|
-
end
|
705
|
-
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
|
706
|
-
attr_accessor :discounts
|
707
|
-
# 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`.
|
708
|
-
attr_accessor :metadata
|
709
|
-
# The ID of the price object.
|
710
|
-
attr_accessor :price
|
711
|
-
# Quantity for this item.
|
712
|
-
attr_accessor :quantity
|
713
|
-
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
|
714
|
-
attr_accessor :tax_rates
|
715
|
-
# Options that configure the trial on the subscription item.
|
716
|
-
attr_accessor :trial
|
717
|
-
|
718
|
-
def initialize(
|
719
|
-
discounts: nil,
|
720
|
-
metadata: nil,
|
721
|
-
price: nil,
|
722
|
-
quantity: nil,
|
723
|
-
tax_rates: nil,
|
724
|
-
trial: nil
|
725
|
-
)
|
726
|
-
@discounts = discounts
|
727
|
-
@metadata = metadata
|
728
|
-
@price = price
|
729
|
-
@quantity = quantity
|
730
|
-
@tax_rates = tax_rates
|
731
|
-
@trial = trial
|
732
|
-
end
|
733
|
-
end
|
734
|
-
|
735
|
-
class RemoveDiscount < Stripe::RequestParams
|
736
|
-
# The coupon code to remove from the `discounts` array.
|
737
|
-
attr_accessor :coupon
|
738
|
-
# The ID of a discount to remove from the `discounts` array.
|
739
|
-
attr_accessor :discount
|
740
|
-
# The ID of a promotion code to remove from the `discounts` array.
|
741
|
-
attr_accessor :promotion_code
|
742
|
-
|
743
|
-
def initialize(coupon: nil, discount: nil, promotion_code: nil)
|
744
|
-
@coupon = coupon
|
745
|
-
@discount = discount
|
746
|
-
@promotion_code = promotion_code
|
747
|
-
end
|
748
|
-
end
|
749
|
-
|
750
|
-
class RemoveItem < Stripe::RequestParams
|
751
|
-
# ID of a price to remove.
|
752
|
-
attr_accessor :price
|
753
|
-
|
754
|
-
def initialize(price: nil)
|
755
|
-
@price = price
|
756
|
-
end
|
757
|
-
end
|
758
|
-
|
759
|
-
class SetDiscount < Stripe::RequestParams
|
760
|
-
# The coupon code to replace the `discounts` array with.
|
761
|
-
attr_accessor :coupon
|
762
|
-
# An ID of an existing discount to replace the `discounts` array with.
|
763
|
-
attr_accessor :discount
|
764
|
-
# An ID of an existing promotion code to replace the `discounts` array with.
|
765
|
-
attr_accessor :promotion_code
|
766
|
-
|
767
|
-
def initialize(coupon: nil, discount: nil, promotion_code: nil)
|
768
|
-
@coupon = coupon
|
769
|
-
@discount = discount
|
770
|
-
@promotion_code = promotion_code
|
771
|
-
end
|
772
|
-
end
|
773
|
-
|
774
|
-
class SetItem < Stripe::RequestParams
|
775
|
-
class Discount < Stripe::RequestParams
|
776
|
-
class DiscountEnd < Stripe::RequestParams
|
777
|
-
class Duration < Stripe::RequestParams
|
778
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
779
|
-
attr_accessor :interval
|
780
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
781
|
-
attr_accessor :interval_count
|
782
|
-
|
783
|
-
def initialize(interval: nil, interval_count: nil)
|
784
|
-
@interval = interval
|
785
|
-
@interval_count = interval_count
|
786
|
-
end
|
787
|
-
end
|
788
|
-
# Time span for the redeemed discount.
|
789
|
-
attr_accessor :duration
|
790
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
791
|
-
attr_accessor :timestamp
|
792
|
-
# The type of calculation made to determine when the discount ends.
|
793
|
-
attr_accessor :type
|
794
|
-
|
795
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
796
|
-
@duration = duration
|
797
|
-
@timestamp = timestamp
|
798
|
-
@type = type
|
799
|
-
end
|
800
|
-
end
|
801
|
-
# ID of the coupon to create a new discount for.
|
802
|
-
attr_accessor :coupon
|
803
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
804
|
-
attr_accessor :discount
|
805
|
-
# Details to determine how long the discount should be applied for.
|
806
|
-
attr_accessor :discount_end
|
807
|
-
# ID of the promotion code to create a new discount for.
|
808
|
-
attr_accessor :promotion_code
|
809
|
-
|
810
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
811
|
-
@coupon = coupon
|
812
|
-
@discount = discount
|
813
|
-
@discount_end = discount_end
|
814
|
-
@promotion_code = promotion_code
|
815
|
-
end
|
816
|
-
end
|
817
|
-
|
818
|
-
class Trial < Stripe::RequestParams
|
819
|
-
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
820
|
-
attr_accessor :converts_to
|
821
|
-
# Determines the type of trial for this item.
|
822
|
-
attr_accessor :type
|
823
|
-
|
824
|
-
def initialize(converts_to: nil, type: nil)
|
825
|
-
@converts_to = converts_to
|
826
|
-
@type = type
|
827
|
-
end
|
828
|
-
end
|
829
|
-
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
|
830
|
-
attr_accessor :discounts
|
831
|
-
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
|
832
|
-
attr_accessor :metadata
|
833
|
-
# The ID of the price object.
|
834
|
-
attr_accessor :price
|
835
|
-
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
|
836
|
-
attr_accessor :quantity
|
837
|
-
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
|
838
|
-
attr_accessor :tax_rates
|
839
|
-
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
|
840
|
-
attr_accessor :trial
|
841
|
-
|
842
|
-
def initialize(
|
843
|
-
discounts: nil,
|
844
|
-
metadata: nil,
|
845
|
-
price: nil,
|
846
|
-
quantity: nil,
|
847
|
-
tax_rates: nil,
|
848
|
-
trial: nil
|
849
|
-
)
|
850
|
-
@discounts = discounts
|
851
|
-
@metadata = metadata
|
852
|
-
@price = price
|
853
|
-
@quantity = quantity
|
854
|
-
@tax_rates = tax_rates
|
855
|
-
@trial = trial
|
856
|
-
end
|
857
|
-
end
|
858
|
-
# Details for the `add_discount` type.
|
859
|
-
attr_accessor :add_discount
|
860
|
-
# Details for the `add_item` type.
|
861
|
-
attr_accessor :add_item
|
862
|
-
# Details for the `add_metadata` type: specify a hash of key-value pairs.
|
863
|
-
attr_accessor :add_metadata
|
864
|
-
# Details for the `remove_discount` type.
|
865
|
-
attr_accessor :remove_discount
|
866
|
-
# Details for the `remove_item` type.
|
867
|
-
attr_accessor :remove_item
|
868
|
-
# Details for the `remove_metadata` type: specify an array of metadata keys.
|
869
|
-
attr_accessor :remove_metadata
|
870
|
-
# Details for the `set_discounts` type.
|
871
|
-
attr_accessor :set_discounts
|
872
|
-
# Details for the `set_items` type.
|
873
|
-
attr_accessor :set_items
|
874
|
-
# Details for the `set_metadata` type: specify an array of key-value pairs.
|
875
|
-
attr_accessor :set_metadata
|
876
|
-
# The type of action the quote line performs.
|
877
|
-
attr_accessor :type
|
878
|
-
|
879
|
-
def initialize(
|
880
|
-
add_discount: nil,
|
881
|
-
add_item: nil,
|
882
|
-
add_metadata: nil,
|
883
|
-
remove_discount: nil,
|
884
|
-
remove_item: nil,
|
885
|
-
remove_metadata: nil,
|
886
|
-
set_discounts: nil,
|
887
|
-
set_items: nil,
|
888
|
-
set_metadata: nil,
|
889
|
-
type: nil
|
890
|
-
)
|
891
|
-
@add_discount = add_discount
|
892
|
-
@add_item = add_item
|
893
|
-
@add_metadata = add_metadata
|
894
|
-
@remove_discount = remove_discount
|
895
|
-
@remove_item = remove_item
|
896
|
-
@remove_metadata = remove_metadata
|
897
|
-
@set_discounts = set_discounts
|
898
|
-
@set_items = set_items
|
899
|
-
@set_metadata = set_metadata
|
900
|
-
@type = type
|
901
|
-
end
|
902
|
-
end
|
903
|
-
|
904
|
-
class AppliesTo < Stripe::RequestParams
|
905
|
-
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
|
906
|
-
attr_accessor :new_reference
|
907
|
-
# The ID of the schedule the line applies to.
|
908
|
-
attr_accessor :subscription_schedule
|
909
|
-
# Describes whether the quote line is affecting a new schedule or an existing schedule.
|
910
|
-
attr_accessor :type
|
911
|
-
|
912
|
-
def initialize(new_reference: nil, subscription_schedule: nil, type: nil)
|
913
|
-
@new_reference = new_reference
|
914
|
-
@subscription_schedule = subscription_schedule
|
915
|
-
@type = type
|
916
|
-
end
|
917
|
-
end
|
918
|
-
|
919
|
-
class CancelSubscriptionSchedule < Stripe::RequestParams
|
920
|
-
# Timestamp helper to cancel the underlying schedule on the accompanying line's start date. Must be set to `line_starts_at`.
|
921
|
-
attr_accessor :cancel_at
|
922
|
-
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Boolean that defaults to `true`.
|
923
|
-
attr_accessor :invoice_now
|
924
|
-
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Boolean that defaults to `true`.
|
925
|
-
attr_accessor :prorate
|
926
|
-
|
927
|
-
def initialize(cancel_at: nil, invoice_now: nil, prorate: nil)
|
928
|
-
@cancel_at = cancel_at
|
929
|
-
@invoice_now = invoice_now
|
930
|
-
@prorate = prorate
|
931
|
-
end
|
932
|
-
end
|
933
|
-
|
934
|
-
class EndsAt < Stripe::RequestParams
|
935
|
-
class DiscountEnd < Stripe::RequestParams
|
936
|
-
# The ID of a specific discount.
|
937
|
-
attr_accessor :discount
|
938
|
-
|
939
|
-
def initialize(discount: nil)
|
940
|
-
@discount = discount
|
941
|
-
end
|
942
|
-
end
|
943
|
-
|
944
|
-
class Duration < Stripe::RequestParams
|
945
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
946
|
-
attr_accessor :interval
|
947
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
948
|
-
attr_accessor :interval_count
|
949
|
-
|
950
|
-
def initialize(interval: nil, interval_count: nil)
|
951
|
-
@interval = interval
|
952
|
-
@interval_count = interval_count
|
953
|
-
end
|
954
|
-
end
|
955
|
-
# Use the `end` time of a given discount.
|
956
|
-
attr_accessor :discount_end
|
957
|
-
# Time span for the quote line starting from the `starts_at` date.
|
958
|
-
attr_accessor :duration
|
959
|
-
# A precise Unix timestamp.
|
960
|
-
attr_accessor :timestamp
|
961
|
-
# Select a way to pass in `ends_at`.
|
962
|
-
attr_accessor :type
|
963
|
-
|
964
|
-
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil)
|
965
|
-
@discount_end = discount_end
|
966
|
-
@duration = duration
|
967
|
-
@timestamp = timestamp
|
968
|
-
@type = type
|
969
|
-
end
|
970
|
-
end
|
971
|
-
|
972
|
-
class SetPauseCollection < Stripe::RequestParams
|
973
|
-
class Set < Stripe::RequestParams
|
974
|
-
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
|
975
|
-
attr_accessor :behavior
|
976
|
-
|
977
|
-
def initialize(behavior: nil)
|
978
|
-
@behavior = behavior
|
979
|
-
end
|
980
|
-
end
|
981
|
-
# Details of the pause_collection behavior to apply to the amendment.
|
982
|
-
attr_accessor :set
|
983
|
-
# Determines the type of the pause_collection amendment.
|
984
|
-
attr_accessor :type
|
985
|
-
|
986
|
-
def initialize(set: nil, type: nil)
|
987
|
-
@set = set
|
988
|
-
@type = type
|
989
|
-
end
|
990
|
-
end
|
991
|
-
|
992
|
-
class StartsAt < Stripe::RequestParams
|
993
|
-
class DiscountEnd < Stripe::RequestParams
|
994
|
-
# The ID of a specific discount.
|
995
|
-
attr_accessor :discount
|
996
|
-
|
997
|
-
def initialize(discount: nil)
|
998
|
-
@discount = discount
|
999
|
-
end
|
1000
|
-
end
|
1001
|
-
|
1002
|
-
class LineEndsAt < Stripe::RequestParams
|
1003
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
1004
|
-
attr_accessor :index
|
1005
|
-
|
1006
|
-
def initialize(index: nil)
|
1007
|
-
@index = index
|
1008
|
-
end
|
1009
|
-
end
|
1010
|
-
# Use the `end` time of a given discount.
|
1011
|
-
attr_accessor :discount_end
|
1012
|
-
# The timestamp the given line ends at.
|
1013
|
-
attr_accessor :line_ends_at
|
1014
|
-
# A precise Unix timestamp.
|
1015
|
-
attr_accessor :timestamp
|
1016
|
-
# Select a way to pass in `starts_at`.
|
1017
|
-
attr_accessor :type
|
1018
|
-
|
1019
|
-
def initialize(discount_end: nil, line_ends_at: nil, timestamp: nil, type: nil)
|
1020
|
-
@discount_end = discount_end
|
1021
|
-
@line_ends_at = line_ends_at
|
1022
|
-
@timestamp = timestamp
|
1023
|
-
@type = type
|
1024
|
-
end
|
1025
|
-
end
|
1026
|
-
|
1027
|
-
class TrialSettings < Stripe::RequestParams
|
1028
|
-
class EndBehavior < Stripe::RequestParams
|
1029
|
-
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
|
1030
|
-
attr_accessor :prorate_up_front
|
1031
|
-
|
1032
|
-
def initialize(prorate_up_front: nil)
|
1033
|
-
@prorate_up_front = prorate_up_front
|
1034
|
-
end
|
1035
|
-
end
|
1036
|
-
# Defines how the subscription should behave when a trial ends.
|
1037
|
-
attr_accessor :end_behavior
|
1038
|
-
|
1039
|
-
def initialize(end_behavior: nil)
|
1040
|
-
@end_behavior = end_behavior
|
1041
|
-
end
|
1042
|
-
end
|
1043
|
-
# An array of operations the quote line performs.
|
1044
|
-
attr_accessor :actions
|
1045
|
-
# Details to identify the subscription schedule the quote line applies to.
|
1046
|
-
attr_accessor :applies_to
|
1047
|
-
# For point-in-time quote lines (having no `ends_at` timestamp), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the Quote Line `starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.
|
1048
|
-
attr_accessor :billing_cycle_anchor
|
1049
|
-
# A point-in-time operation that cancels an existing subscription schedule at the line's starts_at timestamp. Currently only compatible with `quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.
|
1050
|
-
attr_accessor :cancel_subscription_schedule
|
1051
|
-
# Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at `starts_at`, and a restricted set of attributes is supported on the quote line.
|
1052
|
-
attr_accessor :ends_at
|
1053
|
-
# Changes to how Stripe handles prorations during the quote line's time span. Affects if and how prorations are created when a future phase starts.
|
1054
|
-
attr_accessor :proration_behavior
|
1055
|
-
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
|
1056
|
-
attr_accessor :set_pause_collection
|
1057
|
-
# Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date.
|
1058
|
-
attr_accessor :set_schedule_end
|
1059
|
-
# Details to identify the earliest timestamp where the proposed change should take effect.
|
1060
|
-
attr_accessor :starts_at
|
1061
|
-
# Settings related to subscription trials.
|
1062
|
-
attr_accessor :trial_settings
|
1063
|
-
|
1064
|
-
def initialize(
|
1065
|
-
actions: nil,
|
1066
|
-
applies_to: nil,
|
1067
|
-
billing_cycle_anchor: nil,
|
1068
|
-
cancel_subscription_schedule: nil,
|
1069
|
-
ends_at: nil,
|
1070
|
-
proration_behavior: nil,
|
1071
|
-
set_pause_collection: nil,
|
1072
|
-
set_schedule_end: nil,
|
1073
|
-
starts_at: nil,
|
1074
|
-
trial_settings: nil
|
1075
|
-
)
|
1076
|
-
@actions = actions
|
1077
|
-
@applies_to = applies_to
|
1078
|
-
@billing_cycle_anchor = billing_cycle_anchor
|
1079
|
-
@cancel_subscription_schedule = cancel_subscription_schedule
|
1080
|
-
@ends_at = ends_at
|
1081
|
-
@proration_behavior = proration_behavior
|
1082
|
-
@set_pause_collection = set_pause_collection
|
1083
|
-
@set_schedule_end = set_schedule_end
|
1084
|
-
@starts_at = starts_at
|
1085
|
-
@trial_settings = trial_settings
|
1086
|
-
end
|
1087
|
-
end
|
1088
|
-
|
1089
|
-
class LineItem < Stripe::RequestParams
|
1090
|
-
class Discount < Stripe::RequestParams
|
1091
|
-
class DiscountEnd < Stripe::RequestParams
|
1092
|
-
class Duration < Stripe::RequestParams
|
1093
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
1094
|
-
attr_accessor :interval
|
1095
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
1096
|
-
attr_accessor :interval_count
|
1097
|
-
|
1098
|
-
def initialize(interval: nil, interval_count: nil)
|
1099
|
-
@interval = interval
|
1100
|
-
@interval_count = interval_count
|
1101
|
-
end
|
1102
|
-
end
|
1103
|
-
# Time span for the redeemed discount.
|
1104
|
-
attr_accessor :duration
|
1105
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
1106
|
-
attr_accessor :timestamp
|
1107
|
-
# The type of calculation made to determine when the discount ends.
|
1108
|
-
attr_accessor :type
|
1109
|
-
|
1110
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
1111
|
-
@duration = duration
|
1112
|
-
@timestamp = timestamp
|
1113
|
-
@type = type
|
1114
|
-
end
|
1115
|
-
end
|
1116
|
-
# ID of the coupon to create a new discount for.
|
1117
|
-
attr_accessor :coupon
|
1118
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
1119
|
-
attr_accessor :discount
|
1120
|
-
# Details to determine how long the discount should be applied for.
|
1121
|
-
attr_accessor :discount_end
|
1122
|
-
# ID of the promotion code to create a new discount for.
|
1123
|
-
attr_accessor :promotion_code
|
1124
|
-
|
1125
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
1126
|
-
@coupon = coupon
|
1127
|
-
@discount = discount
|
1128
|
-
@discount_end = discount_end
|
1129
|
-
@promotion_code = promotion_code
|
1130
|
-
end
|
1131
|
-
end
|
1132
|
-
|
1133
|
-
class PriceData < Stripe::RequestParams
|
1134
|
-
class Recurring < Stripe::RequestParams
|
1135
|
-
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
|
1136
|
-
attr_accessor :interval
|
1137
|
-
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
|
1138
|
-
attr_accessor :interval_count
|
1139
|
-
|
1140
|
-
def initialize(interval: nil, interval_count: nil)
|
1141
|
-
@interval = interval
|
1142
|
-
@interval_count = interval_count
|
1143
|
-
end
|
1144
|
-
end
|
1145
|
-
# 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).
|
1146
|
-
attr_accessor :currency
|
1147
|
-
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
|
1148
|
-
attr_accessor :product
|
1149
|
-
# The recurring components of a price such as `interval` and `interval_count`.
|
1150
|
-
attr_accessor :recurring
|
1151
|
-
# Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
|
1152
|
-
attr_accessor :tax_behavior
|
1153
|
-
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
|
1154
|
-
attr_accessor :unit_amount
|
1155
|
-
# Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
|
1156
|
-
attr_accessor :unit_amount_decimal
|
1157
|
-
|
1158
|
-
def initialize(
|
1159
|
-
currency: nil,
|
1160
|
-
product: nil,
|
1161
|
-
recurring: nil,
|
1162
|
-
tax_behavior: nil,
|
1163
|
-
unit_amount: nil,
|
1164
|
-
unit_amount_decimal: nil
|
1165
|
-
)
|
1166
|
-
@currency = currency
|
1167
|
-
@product = product
|
1168
|
-
@recurring = recurring
|
1169
|
-
@tax_behavior = tax_behavior
|
1170
|
-
@unit_amount = unit_amount
|
1171
|
-
@unit_amount_decimal = unit_amount_decimal
|
1172
|
-
end
|
1173
|
-
end
|
1174
|
-
# The discounts applied to this line item.
|
1175
|
-
attr_accessor :discounts
|
1176
|
-
# The ID of the price object. One of `price` or `price_data` is required.
|
1177
|
-
attr_accessor :price
|
1178
|
-
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
|
1179
|
-
attr_accessor :price_data
|
1180
|
-
# The quantity of the line item.
|
1181
|
-
attr_accessor :quantity
|
1182
|
-
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
|
1183
|
-
attr_accessor :tax_rates
|
1184
|
-
|
1185
|
-
def initialize(discounts: nil, price: nil, price_data: nil, quantity: nil, tax_rates: nil)
|
1186
|
-
@discounts = discounts
|
1187
|
-
@price = price
|
1188
|
-
@price_data = price_data
|
1189
|
-
@quantity = quantity
|
1190
|
-
@tax_rates = tax_rates
|
1191
|
-
end
|
1192
|
-
end
|
1193
|
-
|
1194
|
-
class SubscriptionData < Stripe::RequestParams
|
1195
|
-
class BillOnAcceptance < Stripe::RequestParams
|
1196
|
-
class BillFrom < Stripe::RequestParams
|
1197
|
-
class LineStartsAt < Stripe::RequestParams
|
1198
|
-
# The ID of a quote line.
|
1199
|
-
attr_accessor :id
|
1200
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
1201
|
-
attr_accessor :index
|
1202
|
-
|
1203
|
-
def initialize(id: nil, index: nil)
|
1204
|
-
@id = id
|
1205
|
-
@index = index
|
1206
|
-
end
|
1207
|
-
end
|
1208
|
-
# Details of a Quote line to start the bill period from.
|
1209
|
-
attr_accessor :line_starts_at
|
1210
|
-
# A precise Unix timestamp.
|
1211
|
-
attr_accessor :timestamp
|
1212
|
-
# The type of method to specify the `bill_from` time.
|
1213
|
-
attr_accessor :type
|
1214
|
-
|
1215
|
-
def initialize(line_starts_at: nil, timestamp: nil, type: nil)
|
1216
|
-
@line_starts_at = line_starts_at
|
1217
|
-
@timestamp = timestamp
|
1218
|
-
@type = type
|
1219
|
-
end
|
1220
|
-
end
|
1221
|
-
|
1222
|
-
class BillUntil < Stripe::RequestParams
|
1223
|
-
class Duration < Stripe::RequestParams
|
1224
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
1225
|
-
attr_accessor :interval
|
1226
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
1227
|
-
attr_accessor :interval_count
|
1228
|
-
|
1229
|
-
def initialize(interval: nil, interval_count: nil)
|
1230
|
-
@interval = interval
|
1231
|
-
@interval_count = interval_count
|
1232
|
-
end
|
1233
|
-
end
|
1234
|
-
|
1235
|
-
class LineEndsAt < Stripe::RequestParams
|
1236
|
-
# The ID of a quote line.
|
1237
|
-
attr_accessor :id
|
1238
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
1239
|
-
attr_accessor :index
|
1240
|
-
|
1241
|
-
def initialize(id: nil, index: nil)
|
1242
|
-
@id = id
|
1243
|
-
@index = index
|
1244
|
-
end
|
1245
|
-
end
|
1246
|
-
# Details of the duration over which to bill.
|
1247
|
-
attr_accessor :duration
|
1248
|
-
# Details of a Quote line item from which to bill until.
|
1249
|
-
attr_accessor :line_ends_at
|
1250
|
-
# A precise Unix timestamp.
|
1251
|
-
attr_accessor :timestamp
|
1252
|
-
# The type of method to specify the `bill_until` time.
|
1253
|
-
attr_accessor :type
|
1254
|
-
|
1255
|
-
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil)
|
1256
|
-
@duration = duration
|
1257
|
-
@line_ends_at = line_ends_at
|
1258
|
-
@timestamp = timestamp
|
1259
|
-
@type = type
|
1260
|
-
end
|
1261
|
-
end
|
1262
|
-
# The start of the period to bill from when the Quote is accepted.
|
1263
|
-
attr_accessor :bill_from
|
1264
|
-
# The end of the period to bill until when the Quote is accepted.
|
1265
|
-
attr_accessor :bill_until
|
1266
|
-
|
1267
|
-
def initialize(bill_from: nil, bill_until: nil)
|
1268
|
-
@bill_from = bill_from
|
1269
|
-
@bill_until = bill_until
|
1270
|
-
end
|
1271
|
-
end
|
1272
|
-
|
1273
|
-
class BillingMode < Stripe::RequestParams
|
1274
|
-
# Controls the calculation and orchestration of prorations and invoices for subscriptions.
|
1275
|
-
attr_accessor :type
|
1276
|
-
|
1277
|
-
def initialize(type: nil)
|
1278
|
-
@type = type
|
1279
|
-
end
|
1280
|
-
end
|
1281
|
-
|
1282
|
-
class Prebilling < Stripe::RequestParams
|
1283
|
-
# This is used to determine the number of billing cycles to prebill.
|
1284
|
-
attr_accessor :iterations
|
1285
|
-
|
1286
|
-
def initialize(iterations: nil)
|
1287
|
-
@iterations = iterations
|
1288
|
-
end
|
1289
|
-
end
|
1290
|
-
# Describes the period to bill for upon accepting the quote.
|
1291
|
-
attr_accessor :bill_on_acceptance
|
1292
|
-
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
1293
|
-
attr_accessor :billing_behavior
|
1294
|
-
# When specified as `reset`, the subscription will always start a new billing period when the quote is accepted.
|
1295
|
-
attr_accessor :billing_cycle_anchor
|
1296
|
-
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
|
1297
|
-
attr_accessor :billing_mode
|
1298
|
-
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
|
1299
|
-
attr_accessor :description
|
1300
|
-
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. When updating a subscription, the date of which the subscription will be updated using a subscription schedule. The special value `current_period_end` can be provided to update a subscription at the end of its current period. The `effective_date` is ignored if it is in the past when the quote is accepted.
|
1301
|
-
attr_accessor :effective_date
|
1302
|
-
# Behavior of the subscription schedule and underlying subscription when it ends.
|
1303
|
-
attr_accessor :end_behavior
|
1304
|
-
# The id of a subscription that the quote will update. By default, the quote will contain the state of the subscription (such as line items, collection method and billing thresholds) unless overridden.
|
1305
|
-
attr_accessor :from_subscription
|
1306
|
-
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
|
1307
|
-
attr_accessor :metadata
|
1308
|
-
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
|
1309
|
-
attr_accessor :prebilling
|
1310
|
-
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
|
1311
|
-
#
|
1312
|
-
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
|
1313
|
-
#
|
1314
|
-
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
|
1315
|
-
#
|
1316
|
-
# Prorations can be disabled by passing `none`.
|
1317
|
-
attr_accessor :proration_behavior
|
1318
|
-
# Integer representing the number of trial period days before the customer is charged for the first time.
|
1319
|
-
attr_accessor :trial_period_days
|
1320
|
-
|
1321
|
-
def initialize(
|
1322
|
-
bill_on_acceptance: nil,
|
1323
|
-
billing_behavior: nil,
|
1324
|
-
billing_cycle_anchor: nil,
|
1325
|
-
billing_mode: nil,
|
1326
|
-
description: nil,
|
1327
|
-
effective_date: nil,
|
1328
|
-
end_behavior: nil,
|
1329
|
-
from_subscription: nil,
|
1330
|
-
metadata: nil,
|
1331
|
-
prebilling: nil,
|
1332
|
-
proration_behavior: nil,
|
1333
|
-
trial_period_days: nil
|
1334
|
-
)
|
1335
|
-
@bill_on_acceptance = bill_on_acceptance
|
1336
|
-
@billing_behavior = billing_behavior
|
1337
|
-
@billing_cycle_anchor = billing_cycle_anchor
|
1338
|
-
@billing_mode = billing_mode
|
1339
|
-
@description = description
|
1340
|
-
@effective_date = effective_date
|
1341
|
-
@end_behavior = end_behavior
|
1342
|
-
@from_subscription = from_subscription
|
1343
|
-
@metadata = metadata
|
1344
|
-
@prebilling = prebilling
|
1345
|
-
@proration_behavior = proration_behavior
|
1346
|
-
@trial_period_days = trial_period_days
|
1347
|
-
end
|
1348
|
-
end
|
1349
|
-
|
1350
|
-
class SubscriptionDataOverride < Stripe::RequestParams
|
1351
|
-
class AppliesTo < Stripe::RequestParams
|
1352
|
-
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
|
1353
|
-
attr_accessor :new_reference
|
1354
|
-
# The ID of the schedule the line applies to.
|
1355
|
-
attr_accessor :subscription_schedule
|
1356
|
-
# Describes whether the quote line is affecting a new schedule or an existing schedule.
|
1357
|
-
attr_accessor :type
|
1358
|
-
|
1359
|
-
def initialize(new_reference: nil, subscription_schedule: nil, type: nil)
|
1360
|
-
@new_reference = new_reference
|
1361
|
-
@subscription_schedule = subscription_schedule
|
1362
|
-
@type = type
|
1363
|
-
end
|
1364
|
-
end
|
1365
|
-
|
1366
|
-
class BillOnAcceptance < Stripe::RequestParams
|
1367
|
-
class BillFrom < Stripe::RequestParams
|
1368
|
-
class LineStartsAt < Stripe::RequestParams
|
1369
|
-
# The ID of a quote line.
|
1370
|
-
attr_accessor :id
|
1371
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
1372
|
-
attr_accessor :index
|
1373
|
-
|
1374
|
-
def initialize(id: nil, index: nil)
|
1375
|
-
@id = id
|
1376
|
-
@index = index
|
1377
|
-
end
|
1378
|
-
end
|
1379
|
-
# Details of a Quote line to start the bill period from.
|
1380
|
-
attr_accessor :line_starts_at
|
1381
|
-
# A precise Unix timestamp.
|
1382
|
-
attr_accessor :timestamp
|
1383
|
-
# The type of method to specify the `bill_from` time.
|
1384
|
-
attr_accessor :type
|
1385
|
-
|
1386
|
-
def initialize(line_starts_at: nil, timestamp: nil, type: nil)
|
1387
|
-
@line_starts_at = line_starts_at
|
1388
|
-
@timestamp = timestamp
|
1389
|
-
@type = type
|
1390
|
-
end
|
1391
|
-
end
|
1392
|
-
|
1393
|
-
class BillUntil < Stripe::RequestParams
|
1394
|
-
class Duration < Stripe::RequestParams
|
1395
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
1396
|
-
attr_accessor :interval
|
1397
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
1398
|
-
attr_accessor :interval_count
|
1399
|
-
|
1400
|
-
def initialize(interval: nil, interval_count: nil)
|
1401
|
-
@interval = interval
|
1402
|
-
@interval_count = interval_count
|
1403
|
-
end
|
1404
|
-
end
|
1405
|
-
|
1406
|
-
class LineEndsAt < Stripe::RequestParams
|
1407
|
-
# The ID of a quote line.
|
1408
|
-
attr_accessor :id
|
1409
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
1410
|
-
attr_accessor :index
|
1411
|
-
|
1412
|
-
def initialize(id: nil, index: nil)
|
1413
|
-
@id = id
|
1414
|
-
@index = index
|
1415
|
-
end
|
1416
|
-
end
|
1417
|
-
# Details of the duration over which to bill.
|
1418
|
-
attr_accessor :duration
|
1419
|
-
# Details of a Quote line item from which to bill until.
|
1420
|
-
attr_accessor :line_ends_at
|
1421
|
-
# A precise Unix timestamp.
|
1422
|
-
attr_accessor :timestamp
|
1423
|
-
# The type of method to specify the `bill_until` time.
|
1424
|
-
attr_accessor :type
|
1425
|
-
|
1426
|
-
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil)
|
1427
|
-
@duration = duration
|
1428
|
-
@line_ends_at = line_ends_at
|
1429
|
-
@timestamp = timestamp
|
1430
|
-
@type = type
|
1431
|
-
end
|
1432
|
-
end
|
1433
|
-
# The start of the period to bill from when the Quote is accepted.
|
1434
|
-
attr_accessor :bill_from
|
1435
|
-
# The end of the period to bill until when the Quote is accepted.
|
1436
|
-
attr_accessor :bill_until
|
1437
|
-
|
1438
|
-
def initialize(bill_from: nil, bill_until: nil)
|
1439
|
-
@bill_from = bill_from
|
1440
|
-
@bill_until = bill_until
|
1441
|
-
end
|
1442
|
-
end
|
1443
|
-
# Whether the override applies to an existing Subscription Schedule or a new Subscription Schedule.
|
1444
|
-
attr_accessor :applies_to
|
1445
|
-
# Describes the period to bill for upon accepting the quote.
|
1446
|
-
attr_accessor :bill_on_acceptance
|
1447
|
-
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
1448
|
-
attr_accessor :billing_behavior
|
1449
|
-
# The customer the Subscription Data override applies to. This is only relevant when `applies_to.type=new_reference`.
|
1450
|
-
attr_accessor :customer
|
1451
|
-
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
|
1452
|
-
attr_accessor :description
|
1453
|
-
# Behavior of the subscription schedule and underlying subscription when it ends.
|
1454
|
-
attr_accessor :end_behavior
|
1455
|
-
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
|
1456
|
-
#
|
1457
|
-
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
|
1458
|
-
#
|
1459
|
-
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
|
1460
|
-
#
|
1461
|
-
# Prorations can be disabled by passing `none`.
|
1462
|
-
attr_accessor :proration_behavior
|
1463
|
-
|
1464
|
-
def initialize(
|
1465
|
-
applies_to: nil,
|
1466
|
-
bill_on_acceptance: nil,
|
1467
|
-
billing_behavior: nil,
|
1468
|
-
customer: nil,
|
1469
|
-
description: nil,
|
1470
|
-
end_behavior: nil,
|
1471
|
-
proration_behavior: nil
|
1472
|
-
)
|
1473
|
-
@applies_to = applies_to
|
1474
|
-
@bill_on_acceptance = bill_on_acceptance
|
1475
|
-
@billing_behavior = billing_behavior
|
1476
|
-
@customer = customer
|
1477
|
-
@description = description
|
1478
|
-
@end_behavior = end_behavior
|
1479
|
-
@proration_behavior = proration_behavior
|
1480
|
-
end
|
1481
|
-
end
|
1482
|
-
|
1483
|
-
class TransferData < Stripe::RequestParams
|
1484
|
-
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
|
1485
|
-
attr_accessor :amount
|
1486
|
-
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
|
1487
|
-
attr_accessor :amount_percent
|
1488
|
-
# ID of an existing, connected Stripe account.
|
1489
|
-
attr_accessor :destination
|
1490
|
-
|
1491
|
-
def initialize(amount: nil, amount_percent: nil, destination: nil)
|
1492
|
-
@amount = amount
|
1493
|
-
@amount_percent = amount_percent
|
1494
|
-
@destination = destination
|
1495
|
-
end
|
1496
|
-
end
|
1497
|
-
# Set to true to allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
|
1498
|
-
attr_accessor :allow_backdated_lines
|
1499
|
-
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
|
1500
|
-
attr_accessor :application_fee_amount
|
1501
|
-
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
|
1502
|
-
attr_accessor :application_fee_percent
|
1503
|
-
# Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
|
1504
|
-
attr_accessor :automatic_tax
|
1505
|
-
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
|
1506
|
-
attr_accessor :collection_method
|
1507
|
-
# The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
|
1508
|
-
attr_accessor :customer
|
1509
|
-
# The account for which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
|
1510
|
-
attr_accessor :customer_account
|
1511
|
-
# The tax rates that will apply to any line item that does not have `tax_rates` set.
|
1512
|
-
attr_accessor :default_tax_rates
|
1513
|
-
# A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
|
1514
|
-
attr_accessor :description
|
1515
|
-
# The discounts applied to the quote.
|
1516
|
-
attr_accessor :discounts
|
1517
|
-
# Specifies which fields in the response should be expanded.
|
1518
|
-
attr_accessor :expand
|
1519
|
-
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
|
1520
|
-
attr_accessor :expires_at
|
1521
|
-
# A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
|
1522
|
-
attr_accessor :footer
|
1523
|
-
# Clone an existing quote. The new quote will be created in `status=draft`. When using this parameter, you cannot specify any other parameters except for `expires_at`.
|
1524
|
-
attr_accessor :from_quote
|
1525
|
-
# A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
|
1526
|
-
attr_accessor :header
|
1527
|
-
# All invoices will be billed using the specified settings.
|
1528
|
-
attr_accessor :invoice_settings
|
1529
|
-
# A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
|
1530
|
-
attr_accessor :line_items
|
1531
|
-
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
|
1532
|
-
attr_accessor :lines
|
1533
|
-
# 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`.
|
1534
|
-
attr_accessor :metadata
|
1535
|
-
# The account on behalf of which to charge.
|
1536
|
-
attr_accessor :on_behalf_of
|
1537
|
-
# When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
|
1538
|
-
attr_accessor :subscription_data
|
1539
|
-
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
|
1540
|
-
attr_accessor :subscription_data_overrides
|
1541
|
-
# ID of the test clock to attach to the quote.
|
1542
|
-
attr_accessor :test_clock
|
1543
|
-
# The data with which to automatically create a Transfer for each of the invoices.
|
1544
|
-
attr_accessor :transfer_data
|
1545
|
-
|
1546
|
-
def initialize(
|
1547
|
-
allow_backdated_lines: nil,
|
1548
|
-
application_fee_amount: nil,
|
1549
|
-
application_fee_percent: nil,
|
1550
|
-
automatic_tax: nil,
|
1551
|
-
collection_method: nil,
|
1552
|
-
customer: nil,
|
1553
|
-
customer_account: nil,
|
1554
|
-
default_tax_rates: nil,
|
1555
|
-
description: nil,
|
1556
|
-
discounts: nil,
|
1557
|
-
expand: nil,
|
1558
|
-
expires_at: nil,
|
1559
|
-
footer: nil,
|
1560
|
-
from_quote: nil,
|
1561
|
-
header: nil,
|
1562
|
-
invoice_settings: nil,
|
1563
|
-
line_items: nil,
|
1564
|
-
lines: nil,
|
1565
|
-
metadata: nil,
|
1566
|
-
on_behalf_of: nil,
|
1567
|
-
subscription_data: nil,
|
1568
|
-
subscription_data_overrides: nil,
|
1569
|
-
test_clock: nil,
|
1570
|
-
transfer_data: nil
|
1571
|
-
)
|
1572
|
-
@allow_backdated_lines = allow_backdated_lines
|
1573
|
-
@application_fee_amount = application_fee_amount
|
1574
|
-
@application_fee_percent = application_fee_percent
|
1575
|
-
@automatic_tax = automatic_tax
|
1576
|
-
@collection_method = collection_method
|
1577
|
-
@customer = customer
|
1578
|
-
@customer_account = customer_account
|
1579
|
-
@default_tax_rates = default_tax_rates
|
1580
|
-
@description = description
|
1581
|
-
@discounts = discounts
|
1582
|
-
@expand = expand
|
1583
|
-
@expires_at = expires_at
|
1584
|
-
@footer = footer
|
1585
|
-
@from_quote = from_quote
|
1586
|
-
@header = header
|
1587
|
-
@invoice_settings = invoice_settings
|
1588
|
-
@line_items = line_items
|
1589
|
-
@lines = lines
|
1590
|
-
@metadata = metadata
|
1591
|
-
@on_behalf_of = on_behalf_of
|
1592
|
-
@subscription_data = subscription_data
|
1593
|
-
@subscription_data_overrides = subscription_data_overrides
|
1594
|
-
@test_clock = test_clock
|
1595
|
-
@transfer_data = transfer_data
|
1596
|
-
end
|
1597
|
-
end
|
1598
|
-
|
1599
|
-
class UpdateParams < Stripe::RequestParams
|
1600
|
-
class AutomaticTax < Stripe::RequestParams
|
1601
|
-
class Liability < Stripe::RequestParams
|
1602
|
-
# The connected account being referenced when `type` is `account`.
|
1603
|
-
attr_accessor :account
|
1604
|
-
# Type of the account referenced in the request.
|
1605
|
-
attr_accessor :type
|
1606
|
-
|
1607
|
-
def initialize(account: nil, type: nil)
|
1608
|
-
@account = account
|
1609
|
-
@type = type
|
1610
|
-
end
|
1611
|
-
end
|
1612
|
-
# Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
|
1613
|
-
attr_accessor :enabled
|
1614
|
-
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
|
1615
|
-
attr_accessor :liability
|
1616
|
-
|
1617
|
-
def initialize(enabled: nil, liability: nil)
|
1618
|
-
@enabled = enabled
|
1619
|
-
@liability = liability
|
1620
|
-
end
|
1621
|
-
end
|
1622
|
-
|
1623
|
-
class Discount < Stripe::RequestParams
|
1624
|
-
class DiscountEnd < Stripe::RequestParams
|
1625
|
-
class Duration < Stripe::RequestParams
|
1626
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
1627
|
-
attr_accessor :interval
|
1628
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
1629
|
-
attr_accessor :interval_count
|
1630
|
-
|
1631
|
-
def initialize(interval: nil, interval_count: nil)
|
1632
|
-
@interval = interval
|
1633
|
-
@interval_count = interval_count
|
1634
|
-
end
|
1635
|
-
end
|
1636
|
-
# Time span for the redeemed discount.
|
1637
|
-
attr_accessor :duration
|
1638
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
1639
|
-
attr_accessor :timestamp
|
1640
|
-
# The type of calculation made to determine when the discount ends.
|
1641
|
-
attr_accessor :type
|
1642
|
-
|
1643
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
1644
|
-
@duration = duration
|
1645
|
-
@timestamp = timestamp
|
1646
|
-
@type = type
|
1647
|
-
end
|
1648
|
-
end
|
1649
|
-
# ID of the coupon to create a new discount for.
|
1650
|
-
attr_accessor :coupon
|
1651
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
1652
|
-
attr_accessor :discount
|
1653
|
-
# Details to determine how long the discount should be applied for.
|
1654
|
-
attr_accessor :discount_end
|
1655
|
-
# ID of the promotion code to create a new discount for.
|
1656
|
-
attr_accessor :promotion_code
|
1657
|
-
|
1658
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
1659
|
-
@coupon = coupon
|
1660
|
-
@discount = discount
|
1661
|
-
@discount_end = discount_end
|
1662
|
-
@promotion_code = promotion_code
|
1663
|
-
end
|
1664
|
-
end
|
1665
|
-
|
1666
|
-
class InvoiceSettings < Stripe::RequestParams
|
1667
|
-
class Issuer < Stripe::RequestParams
|
1668
|
-
# The connected account being referenced when `type` is `account`.
|
1669
|
-
attr_accessor :account
|
1670
|
-
# Type of the account referenced in the request.
|
1671
|
-
attr_accessor :type
|
1672
|
-
|
1673
|
-
def initialize(account: nil, type: nil)
|
1674
|
-
@account = account
|
1675
|
-
@type = type
|
1676
|
-
end
|
1677
|
-
end
|
1678
|
-
# Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
|
1679
|
-
attr_accessor :days_until_due
|
1680
|
-
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
|
1681
|
-
attr_accessor :issuer
|
1682
|
-
|
1683
|
-
def initialize(days_until_due: nil, issuer: nil)
|
1684
|
-
@days_until_due = days_until_due
|
1685
|
-
@issuer = issuer
|
1686
|
-
end
|
1687
|
-
end
|
1688
|
-
|
1689
|
-
class Line < Stripe::RequestParams
|
1690
|
-
class Action < Stripe::RequestParams
|
1691
|
-
class AddDiscount < Stripe::RequestParams
|
1692
|
-
class DiscountEnd < Stripe::RequestParams
|
1693
|
-
# The type of calculation made to determine when the discount ends.
|
1694
|
-
attr_accessor :type
|
1695
|
-
|
1696
|
-
def initialize(type: nil)
|
1697
|
-
@type = type
|
1698
|
-
end
|
1699
|
-
end
|
1700
|
-
# The coupon code to redeem.
|
1701
|
-
attr_accessor :coupon
|
1702
|
-
# An ID of an existing discount for a coupon that was already redeemed.
|
1703
|
-
attr_accessor :discount
|
1704
|
-
# Details to determine how long the discount should be applied for.
|
1705
|
-
attr_accessor :discount_end
|
1706
|
-
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
|
1707
|
-
attr_accessor :index
|
1708
|
-
# The promotion code to redeem.
|
1709
|
-
attr_accessor :promotion_code
|
1710
|
-
|
1711
|
-
def initialize(
|
1712
|
-
coupon: nil,
|
1713
|
-
discount: nil,
|
1714
|
-
discount_end: nil,
|
1715
|
-
index: nil,
|
1716
|
-
promotion_code: nil
|
1717
|
-
)
|
1718
|
-
@coupon = coupon
|
1719
|
-
@discount = discount
|
1720
|
-
@discount_end = discount_end
|
1721
|
-
@index = index
|
1722
|
-
@promotion_code = promotion_code
|
1723
|
-
end
|
1724
|
-
end
|
1725
|
-
|
1726
|
-
class AddItem < Stripe::RequestParams
|
1727
|
-
class Discount < Stripe::RequestParams
|
1728
|
-
class DiscountEnd < Stripe::RequestParams
|
1729
|
-
class Duration < Stripe::RequestParams
|
1730
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
1731
|
-
attr_accessor :interval
|
1732
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
1733
|
-
attr_accessor :interval_count
|
1734
|
-
|
1735
|
-
def initialize(interval: nil, interval_count: nil)
|
1736
|
-
@interval = interval
|
1737
|
-
@interval_count = interval_count
|
1738
|
-
end
|
1739
|
-
end
|
1740
|
-
# Time span for the redeemed discount.
|
1741
|
-
attr_accessor :duration
|
1742
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
1743
|
-
attr_accessor :timestamp
|
1744
|
-
# The type of calculation made to determine when the discount ends.
|
1745
|
-
attr_accessor :type
|
1746
|
-
|
1747
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
1748
|
-
@duration = duration
|
1749
|
-
@timestamp = timestamp
|
1750
|
-
@type = type
|
1751
|
-
end
|
1752
|
-
end
|
1753
|
-
# ID of the coupon to create a new discount for.
|
1754
|
-
attr_accessor :coupon
|
1755
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
1756
|
-
attr_accessor :discount
|
1757
|
-
# Details to determine how long the discount should be applied for.
|
1758
|
-
attr_accessor :discount_end
|
1759
|
-
# ID of the promotion code to create a new discount for.
|
1760
|
-
attr_accessor :promotion_code
|
1761
|
-
|
1762
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
1763
|
-
@coupon = coupon
|
1764
|
-
@discount = discount
|
1765
|
-
@discount_end = discount_end
|
1766
|
-
@promotion_code = promotion_code
|
1767
|
-
end
|
1768
|
-
end
|
1769
|
-
|
1770
|
-
class Trial < Stripe::RequestParams
|
1771
|
-
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
1772
|
-
attr_accessor :converts_to
|
1773
|
-
# Determines the type of trial for this item.
|
1774
|
-
attr_accessor :type
|
1775
|
-
|
1776
|
-
def initialize(converts_to: nil, type: nil)
|
1777
|
-
@converts_to = converts_to
|
1778
|
-
@type = type
|
1779
|
-
end
|
1780
|
-
end
|
1781
|
-
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
|
1782
|
-
attr_accessor :discounts
|
1783
|
-
# 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`.
|
1784
|
-
attr_accessor :metadata
|
1785
|
-
# The ID of the price object.
|
1786
|
-
attr_accessor :price
|
1787
|
-
# Quantity for this item.
|
1788
|
-
attr_accessor :quantity
|
1789
|
-
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
|
1790
|
-
attr_accessor :tax_rates
|
1791
|
-
# Options that configure the trial on the subscription item.
|
1792
|
-
attr_accessor :trial
|
1793
|
-
|
1794
|
-
def initialize(
|
1795
|
-
discounts: nil,
|
1796
|
-
metadata: nil,
|
1797
|
-
price: nil,
|
1798
|
-
quantity: nil,
|
1799
|
-
tax_rates: nil,
|
1800
|
-
trial: nil
|
1801
|
-
)
|
1802
|
-
@discounts = discounts
|
1803
|
-
@metadata = metadata
|
1804
|
-
@price = price
|
1805
|
-
@quantity = quantity
|
1806
|
-
@tax_rates = tax_rates
|
1807
|
-
@trial = trial
|
1808
|
-
end
|
1809
|
-
end
|
1810
|
-
|
1811
|
-
class RemoveDiscount < Stripe::RequestParams
|
1812
|
-
# The coupon code to remove from the `discounts` array.
|
1813
|
-
attr_accessor :coupon
|
1814
|
-
# The ID of a discount to remove from the `discounts` array.
|
1815
|
-
attr_accessor :discount
|
1816
|
-
# The ID of a promotion code to remove from the `discounts` array.
|
1817
|
-
attr_accessor :promotion_code
|
1818
|
-
|
1819
|
-
def initialize(coupon: nil, discount: nil, promotion_code: nil)
|
1820
|
-
@coupon = coupon
|
1821
|
-
@discount = discount
|
1822
|
-
@promotion_code = promotion_code
|
1823
|
-
end
|
1824
|
-
end
|
1825
|
-
|
1826
|
-
class RemoveItem < Stripe::RequestParams
|
1827
|
-
# ID of a price to remove.
|
1828
|
-
attr_accessor :price
|
1829
|
-
|
1830
|
-
def initialize(price: nil)
|
1831
|
-
@price = price
|
1832
|
-
end
|
1833
|
-
end
|
1834
|
-
|
1835
|
-
class SetDiscount < Stripe::RequestParams
|
1836
|
-
# The coupon code to replace the `discounts` array with.
|
1837
|
-
attr_accessor :coupon
|
1838
|
-
# An ID of an existing discount to replace the `discounts` array with.
|
1839
|
-
attr_accessor :discount
|
1840
|
-
# An ID of an existing promotion code to replace the `discounts` array with.
|
1841
|
-
attr_accessor :promotion_code
|
1842
|
-
|
1843
|
-
def initialize(coupon: nil, discount: nil, promotion_code: nil)
|
1844
|
-
@coupon = coupon
|
1845
|
-
@discount = discount
|
1846
|
-
@promotion_code = promotion_code
|
1847
|
-
end
|
1848
|
-
end
|
1849
|
-
|
1850
|
-
class SetItem < Stripe::RequestParams
|
1851
|
-
class Discount < Stripe::RequestParams
|
1852
|
-
class DiscountEnd < Stripe::RequestParams
|
1853
|
-
class Duration < Stripe::RequestParams
|
1854
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
1855
|
-
attr_accessor :interval
|
1856
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
1857
|
-
attr_accessor :interval_count
|
1858
|
-
|
1859
|
-
def initialize(interval: nil, interval_count: nil)
|
1860
|
-
@interval = interval
|
1861
|
-
@interval_count = interval_count
|
1862
|
-
end
|
1863
|
-
end
|
1864
|
-
# Time span for the redeemed discount.
|
1865
|
-
attr_accessor :duration
|
1866
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
1867
|
-
attr_accessor :timestamp
|
1868
|
-
# The type of calculation made to determine when the discount ends.
|
1869
|
-
attr_accessor :type
|
1870
|
-
|
1871
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
1872
|
-
@duration = duration
|
1873
|
-
@timestamp = timestamp
|
1874
|
-
@type = type
|
1875
|
-
end
|
1876
|
-
end
|
1877
|
-
# ID of the coupon to create a new discount for.
|
1878
|
-
attr_accessor :coupon
|
1879
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
1880
|
-
attr_accessor :discount
|
1881
|
-
# Details to determine how long the discount should be applied for.
|
1882
|
-
attr_accessor :discount_end
|
1883
|
-
# ID of the promotion code to create a new discount for.
|
1884
|
-
attr_accessor :promotion_code
|
1885
|
-
|
1886
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
1887
|
-
@coupon = coupon
|
1888
|
-
@discount = discount
|
1889
|
-
@discount_end = discount_end
|
1890
|
-
@promotion_code = promotion_code
|
1891
|
-
end
|
1892
|
-
end
|
1893
|
-
|
1894
|
-
class Trial < Stripe::RequestParams
|
1895
|
-
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
|
1896
|
-
attr_accessor :converts_to
|
1897
|
-
# Determines the type of trial for this item.
|
1898
|
-
attr_accessor :type
|
1899
|
-
|
1900
|
-
def initialize(converts_to: nil, type: nil)
|
1901
|
-
@converts_to = converts_to
|
1902
|
-
@type = type
|
1903
|
-
end
|
1904
|
-
end
|
1905
|
-
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
|
1906
|
-
attr_accessor :discounts
|
1907
|
-
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
|
1908
|
-
attr_accessor :metadata
|
1909
|
-
# The ID of the price object.
|
1910
|
-
attr_accessor :price
|
1911
|
-
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
|
1912
|
-
attr_accessor :quantity
|
1913
|
-
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
|
1914
|
-
attr_accessor :tax_rates
|
1915
|
-
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
|
1916
|
-
attr_accessor :trial
|
1917
|
-
|
1918
|
-
def initialize(
|
1919
|
-
discounts: nil,
|
1920
|
-
metadata: nil,
|
1921
|
-
price: nil,
|
1922
|
-
quantity: nil,
|
1923
|
-
tax_rates: nil,
|
1924
|
-
trial: nil
|
1925
|
-
)
|
1926
|
-
@discounts = discounts
|
1927
|
-
@metadata = metadata
|
1928
|
-
@price = price
|
1929
|
-
@quantity = quantity
|
1930
|
-
@tax_rates = tax_rates
|
1931
|
-
@trial = trial
|
1932
|
-
end
|
1933
|
-
end
|
1934
|
-
# Details for the `add_discount` type.
|
1935
|
-
attr_accessor :add_discount
|
1936
|
-
# Details for the `add_item` type.
|
1937
|
-
attr_accessor :add_item
|
1938
|
-
# Details for the `add_metadata` type: specify a hash of key-value pairs.
|
1939
|
-
attr_accessor :add_metadata
|
1940
|
-
# Details for the `remove_discount` type.
|
1941
|
-
attr_accessor :remove_discount
|
1942
|
-
# Details for the `remove_item` type.
|
1943
|
-
attr_accessor :remove_item
|
1944
|
-
# Details for the `remove_metadata` type: specify an array of metadata keys.
|
1945
|
-
attr_accessor :remove_metadata
|
1946
|
-
# Details for the `set_discounts` type.
|
1947
|
-
attr_accessor :set_discounts
|
1948
|
-
# Details for the `set_items` type.
|
1949
|
-
attr_accessor :set_items
|
1950
|
-
# Details for the `set_metadata` type: specify an array of key-value pairs.
|
1951
|
-
attr_accessor :set_metadata
|
1952
|
-
# The type of action the quote line performs.
|
1953
|
-
attr_accessor :type
|
1954
|
-
|
1955
|
-
def initialize(
|
1956
|
-
add_discount: nil,
|
1957
|
-
add_item: nil,
|
1958
|
-
add_metadata: nil,
|
1959
|
-
remove_discount: nil,
|
1960
|
-
remove_item: nil,
|
1961
|
-
remove_metadata: nil,
|
1962
|
-
set_discounts: nil,
|
1963
|
-
set_items: nil,
|
1964
|
-
set_metadata: nil,
|
1965
|
-
type: nil
|
1966
|
-
)
|
1967
|
-
@add_discount = add_discount
|
1968
|
-
@add_item = add_item
|
1969
|
-
@add_metadata = add_metadata
|
1970
|
-
@remove_discount = remove_discount
|
1971
|
-
@remove_item = remove_item
|
1972
|
-
@remove_metadata = remove_metadata
|
1973
|
-
@set_discounts = set_discounts
|
1974
|
-
@set_items = set_items
|
1975
|
-
@set_metadata = set_metadata
|
1976
|
-
@type = type
|
1977
|
-
end
|
1978
|
-
end
|
1979
|
-
|
1980
|
-
class AppliesTo < Stripe::RequestParams
|
1981
|
-
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
|
1982
|
-
attr_accessor :new_reference
|
1983
|
-
# The ID of the schedule the line applies to.
|
1984
|
-
attr_accessor :subscription_schedule
|
1985
|
-
# Describes whether the quote line is affecting a new schedule or an existing schedule.
|
1986
|
-
attr_accessor :type
|
1987
|
-
|
1988
|
-
def initialize(new_reference: nil, subscription_schedule: nil, type: nil)
|
1989
|
-
@new_reference = new_reference
|
1990
|
-
@subscription_schedule = subscription_schedule
|
1991
|
-
@type = type
|
1992
|
-
end
|
1993
|
-
end
|
1994
|
-
|
1995
|
-
class CancelSubscriptionSchedule < Stripe::RequestParams
|
1996
|
-
# Timestamp helper to cancel the underlying schedule on the accompanying line's start date. Must be set to `line_starts_at`.
|
1997
|
-
attr_accessor :cancel_at
|
1998
|
-
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Boolean that defaults to `true`.
|
1999
|
-
attr_accessor :invoice_now
|
2000
|
-
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Boolean that defaults to `true`.
|
2001
|
-
attr_accessor :prorate
|
2002
|
-
|
2003
|
-
def initialize(cancel_at: nil, invoice_now: nil, prorate: nil)
|
2004
|
-
@cancel_at = cancel_at
|
2005
|
-
@invoice_now = invoice_now
|
2006
|
-
@prorate = prorate
|
2007
|
-
end
|
2008
|
-
end
|
2009
|
-
|
2010
|
-
class EndsAt < Stripe::RequestParams
|
2011
|
-
class DiscountEnd < Stripe::RequestParams
|
2012
|
-
# The ID of a specific discount.
|
2013
|
-
attr_accessor :discount
|
2014
|
-
|
2015
|
-
def initialize(discount: nil)
|
2016
|
-
@discount = discount
|
2017
|
-
end
|
2018
|
-
end
|
2019
|
-
|
2020
|
-
class Duration < Stripe::RequestParams
|
2021
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
2022
|
-
attr_accessor :interval
|
2023
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
2024
|
-
attr_accessor :interval_count
|
2025
|
-
|
2026
|
-
def initialize(interval: nil, interval_count: nil)
|
2027
|
-
@interval = interval
|
2028
|
-
@interval_count = interval_count
|
2029
|
-
end
|
2030
|
-
end
|
2031
|
-
# Use the `end` time of a given discount.
|
2032
|
-
attr_accessor :discount_end
|
2033
|
-
# Time span for the quote line starting from the `starts_at` date.
|
2034
|
-
attr_accessor :duration
|
2035
|
-
# A precise Unix timestamp.
|
2036
|
-
attr_accessor :timestamp
|
2037
|
-
# Select a way to pass in `ends_at`.
|
2038
|
-
attr_accessor :type
|
2039
|
-
|
2040
|
-
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil)
|
2041
|
-
@discount_end = discount_end
|
2042
|
-
@duration = duration
|
2043
|
-
@timestamp = timestamp
|
2044
|
-
@type = type
|
2045
|
-
end
|
2046
|
-
end
|
2047
|
-
|
2048
|
-
class SetPauseCollection < Stripe::RequestParams
|
2049
|
-
class Set < Stripe::RequestParams
|
2050
|
-
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
|
2051
|
-
attr_accessor :behavior
|
2052
|
-
|
2053
|
-
def initialize(behavior: nil)
|
2054
|
-
@behavior = behavior
|
2055
|
-
end
|
2056
|
-
end
|
2057
|
-
# Details of the pause_collection behavior to apply to the amendment.
|
2058
|
-
attr_accessor :set
|
2059
|
-
# Determines the type of the pause_collection amendment.
|
2060
|
-
attr_accessor :type
|
2061
|
-
|
2062
|
-
def initialize(set: nil, type: nil)
|
2063
|
-
@set = set
|
2064
|
-
@type = type
|
2065
|
-
end
|
2066
|
-
end
|
2067
|
-
|
2068
|
-
class StartsAt < Stripe::RequestParams
|
2069
|
-
class DiscountEnd < Stripe::RequestParams
|
2070
|
-
# The ID of a specific discount.
|
2071
|
-
attr_accessor :discount
|
2072
|
-
|
2073
|
-
def initialize(discount: nil)
|
2074
|
-
@discount = discount
|
2075
|
-
end
|
2076
|
-
end
|
2077
|
-
|
2078
|
-
class LineEndsAt < Stripe::RequestParams
|
2079
|
-
# The ID of a quote line.
|
2080
|
-
attr_accessor :id
|
2081
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
2082
|
-
attr_accessor :index
|
2083
178
|
|
2084
|
-
|
2085
|
-
|
2086
|
-
|
179
|
+
def self.field_remappings
|
180
|
+
@field_remappings = {}
|
181
|
+
end
|
2087
182
|
end
|
2088
|
-
|
2089
|
-
|
2090
|
-
|
2091
|
-
|
2092
|
-
attr_accessor :line_ends_at
|
2093
|
-
# A precise Unix timestamp.
|
2094
|
-
attr_accessor :timestamp
|
2095
|
-
# Select a way to pass in `starts_at`.
|
2096
|
-
attr_accessor :type
|
2097
|
-
|
2098
|
-
def initialize(discount_end: nil, line_ends_at: nil, timestamp: nil, type: nil)
|
2099
|
-
@discount_end = discount_end
|
2100
|
-
@line_ends_at = line_ends_at
|
2101
|
-
@timestamp = timestamp
|
2102
|
-
@type = type
|
2103
|
-
end
|
2104
|
-
end
|
183
|
+
# The aggregated discounts.
|
184
|
+
attr_reader :discounts
|
185
|
+
# The aggregated tax amounts by rate.
|
186
|
+
attr_reader :taxes
|
2105
187
|
|
2106
|
-
|
2107
|
-
|
2108
|
-
|
2109
|
-
attr_accessor :prorate_up_front
|
188
|
+
def self.inner_class_types
|
189
|
+
@inner_class_types = { discounts: Discount, taxes: Tax }
|
190
|
+
end
|
2110
191
|
|
2111
|
-
def
|
2112
|
-
@
|
192
|
+
def self.field_remappings
|
193
|
+
@field_remappings = {}
|
2113
194
|
end
|
2114
195
|
end
|
2115
|
-
#
|
2116
|
-
|
196
|
+
# This is the sum of all the discounts.
|
197
|
+
attr_reader :amount_discount
|
198
|
+
# This is the sum of all the shipping amounts.
|
199
|
+
attr_reader :amount_shipping
|
200
|
+
# This is the sum of all the tax amounts.
|
201
|
+
attr_reader :amount_tax
|
202
|
+
# Attribute for field breakdown
|
203
|
+
attr_reader :breakdown
|
2117
204
|
|
2118
|
-
def
|
2119
|
-
@
|
205
|
+
def self.inner_class_types
|
206
|
+
@inner_class_types = { breakdown: Breakdown }
|
2120
207
|
end
|
2121
|
-
end
|
2122
|
-
# An array of operations the quote line performs.
|
2123
|
-
attr_accessor :actions
|
2124
|
-
# Details to identify the subscription schedule the quote line applies to.
|
2125
|
-
attr_accessor :applies_to
|
2126
|
-
# For point-in-time quote lines (having no `ends_at` timestamp), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the Quote Line `starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.
|
2127
|
-
attr_accessor :billing_cycle_anchor
|
2128
|
-
# A point-in-time operation that cancels an existing subscription schedule at the line's starts_at timestamp. Currently only compatible with `quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.
|
2129
|
-
attr_accessor :cancel_subscription_schedule
|
2130
|
-
# Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at `starts_at`, and a restricted set of attributes is supported on the quote line.
|
2131
|
-
attr_accessor :ends_at
|
2132
|
-
# The ID of an existing line on the quote.
|
2133
|
-
attr_accessor :id
|
2134
|
-
# Changes to how Stripe handles prorations during the quote line's time span. Affects if and how prorations are created when a future phase starts.
|
2135
|
-
attr_accessor :proration_behavior
|
2136
|
-
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
|
2137
|
-
attr_accessor :set_pause_collection
|
2138
|
-
# Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date.
|
2139
|
-
attr_accessor :set_schedule_end
|
2140
|
-
# Details to identify the earliest timestamp where the proposed change should take effect.
|
2141
|
-
attr_accessor :starts_at
|
2142
|
-
# Settings related to subscription trials.
|
2143
|
-
attr_accessor :trial_settings
|
2144
|
-
|
2145
|
-
def initialize(
|
2146
|
-
actions: nil,
|
2147
|
-
applies_to: nil,
|
2148
|
-
billing_cycle_anchor: nil,
|
2149
|
-
cancel_subscription_schedule: nil,
|
2150
|
-
ends_at: nil,
|
2151
|
-
id: nil,
|
2152
|
-
proration_behavior: nil,
|
2153
|
-
set_pause_collection: nil,
|
2154
|
-
set_schedule_end: nil,
|
2155
|
-
starts_at: nil,
|
2156
|
-
trial_settings: nil
|
2157
|
-
)
|
2158
|
-
@actions = actions
|
2159
|
-
@applies_to = applies_to
|
2160
|
-
@billing_cycle_anchor = billing_cycle_anchor
|
2161
|
-
@cancel_subscription_schedule = cancel_subscription_schedule
|
2162
|
-
@ends_at = ends_at
|
2163
|
-
@id = id
|
2164
|
-
@proration_behavior = proration_behavior
|
2165
|
-
@set_pause_collection = set_pause_collection
|
2166
|
-
@set_schedule_end = set_schedule_end
|
2167
|
-
@starts_at = starts_at
|
2168
|
-
@trial_settings = trial_settings
|
2169
|
-
end
|
2170
|
-
end
|
2171
208
|
|
2172
|
-
|
2173
|
-
|
2174
|
-
class DiscountEnd < Stripe::RequestParams
|
2175
|
-
class Duration < Stripe::RequestParams
|
2176
|
-
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
|
2177
|
-
attr_accessor :interval
|
2178
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
2179
|
-
attr_accessor :interval_count
|
2180
|
-
|
2181
|
-
def initialize(interval: nil, interval_count: nil)
|
2182
|
-
@interval = interval
|
2183
|
-
@interval_count = interval_count
|
2184
|
-
end
|
2185
|
-
end
|
2186
|
-
# Time span for the redeemed discount.
|
2187
|
-
attr_accessor :duration
|
2188
|
-
# A precise Unix timestamp for the discount to end. Must be in the future.
|
2189
|
-
attr_accessor :timestamp
|
2190
|
-
# The type of calculation made to determine when the discount ends.
|
2191
|
-
attr_accessor :type
|
2192
|
-
|
2193
|
-
def initialize(duration: nil, timestamp: nil, type: nil)
|
2194
|
-
@duration = duration
|
2195
|
-
@timestamp = timestamp
|
2196
|
-
@type = type
|
2197
|
-
end
|
2198
|
-
end
|
2199
|
-
# ID of the coupon to create a new discount for.
|
2200
|
-
attr_accessor :coupon
|
2201
|
-
# ID of an existing discount on the object (or one of its ancestors) to reuse.
|
2202
|
-
attr_accessor :discount
|
2203
|
-
# Details to determine how long the discount should be applied for.
|
2204
|
-
attr_accessor :discount_end
|
2205
|
-
# ID of the promotion code to create a new discount for.
|
2206
|
-
attr_accessor :promotion_code
|
2207
|
-
|
2208
|
-
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil)
|
2209
|
-
@coupon = coupon
|
2210
|
-
@discount = discount
|
2211
|
-
@discount_end = discount_end
|
2212
|
-
@promotion_code = promotion_code
|
209
|
+
def self.field_remappings
|
210
|
+
@field_remappings = {}
|
2213
211
|
end
|
2214
212
|
end
|
213
|
+
# Total before any discounts or taxes are applied.
|
214
|
+
attr_reader :amount_subtotal
|
215
|
+
# Total after discounts and taxes are applied.
|
216
|
+
attr_reader :amount_total
|
217
|
+
# The line items that will appear on the next invoice after this quote is accepted. This does not include pending invoice items that exist on the customer but may still be included in the next invoice.
|
218
|
+
attr_reader :line_items
|
219
|
+
# Attribute for field total_details
|
220
|
+
attr_reader :total_details
|
2215
221
|
|
2216
|
-
|
2217
|
-
|
2218
|
-
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
|
2219
|
-
attr_accessor :interval
|
2220
|
-
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
|
2221
|
-
attr_accessor :interval_count
|
2222
|
-
|
2223
|
-
def initialize(interval: nil, interval_count: nil)
|
2224
|
-
@interval = interval
|
2225
|
-
@interval_count = interval_count
|
2226
|
-
end
|
2227
|
-
end
|
2228
|
-
# 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).
|
2229
|
-
attr_accessor :currency
|
2230
|
-
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
|
2231
|
-
attr_accessor :product
|
2232
|
-
# The recurring components of a price such as `interval` and `interval_count`.
|
2233
|
-
attr_accessor :recurring
|
2234
|
-
# Only required if a [default tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#setting-a-default-tax-behavior-(recommended)) was not provided in the Stripe Tax settings. Specifies whether the price is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`. Once specified as either `inclusive` or `exclusive`, it cannot be changed.
|
2235
|
-
attr_accessor :tax_behavior
|
2236
|
-
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
|
2237
|
-
attr_accessor :unit_amount
|
2238
|
-
# Same as `unit_amount`, but accepts a decimal value in cents (or local equivalent) with at most 12 decimal places. Only one of `unit_amount` and `unit_amount_decimal` can be set.
|
2239
|
-
attr_accessor :unit_amount_decimal
|
2240
|
-
|
2241
|
-
def initialize(
|
2242
|
-
currency: nil,
|
2243
|
-
product: nil,
|
2244
|
-
recurring: nil,
|
2245
|
-
tax_behavior: nil,
|
2246
|
-
unit_amount: nil,
|
2247
|
-
unit_amount_decimal: nil
|
2248
|
-
)
|
2249
|
-
@currency = currency
|
2250
|
-
@product = product
|
2251
|
-
@recurring = recurring
|
2252
|
-
@tax_behavior = tax_behavior
|
2253
|
-
@unit_amount = unit_amount
|
2254
|
-
@unit_amount_decimal = unit_amount_decimal
|
2255
|
-
end
|
222
|
+
def self.inner_class_types
|
223
|
+
@inner_class_types = { total_details: TotalDetails }
|
2256
224
|
end
|
2257
|
-
|
2258
|
-
|
2259
|
-
|
2260
|
-
attr_accessor :id
|
2261
|
-
# The ID of the price object. One of `price` or `price_data` is required.
|
2262
|
-
attr_accessor :price
|
2263
|
-
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
|
2264
|
-
attr_accessor :price_data
|
2265
|
-
# The quantity of the line item.
|
2266
|
-
attr_accessor :quantity
|
2267
|
-
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
|
2268
|
-
attr_accessor :tax_rates
|
2269
|
-
|
2270
|
-
def initialize(
|
2271
|
-
discounts: nil,
|
2272
|
-
id: nil,
|
2273
|
-
price: nil,
|
2274
|
-
price_data: nil,
|
2275
|
-
quantity: nil,
|
2276
|
-
tax_rates: nil
|
2277
|
-
)
|
2278
|
-
@discounts = discounts
|
2279
|
-
@id = id
|
2280
|
-
@price = price
|
2281
|
-
@price_data = price_data
|
2282
|
-
@quantity = quantity
|
2283
|
-
@tax_rates = tax_rates
|
225
|
+
|
226
|
+
def self.field_remappings
|
227
|
+
@field_remappings = {}
|
2284
228
|
end
|
2285
229
|
end
|
230
|
+
# The definitive totals and line items the customer will be charged on a recurring basis. Takes into account the line items with recurring prices and discounts with `duration=forever` coupons only. Defaults to `null` if no inputted line items with recurring prices.
|
231
|
+
attr_reader :recurring
|
232
|
+
# Attribute for field upfront
|
233
|
+
attr_reader :upfront
|
2286
234
|
|
2287
|
-
|
2288
|
-
|
2289
|
-
|
2290
|
-
class LineStartsAt < Stripe::RequestParams
|
2291
|
-
# The ID of a quote line.
|
2292
|
-
attr_accessor :id
|
2293
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
2294
|
-
attr_accessor :index
|
2295
|
-
|
2296
|
-
def initialize(id: nil, index: nil)
|
2297
|
-
@id = id
|
2298
|
-
@index = index
|
2299
|
-
end
|
2300
|
-
end
|
2301
|
-
# Details of a Quote line to start the bill period from.
|
2302
|
-
attr_accessor :line_starts_at
|
2303
|
-
# A precise Unix timestamp.
|
2304
|
-
attr_accessor :timestamp
|
2305
|
-
# The type of method to specify the `bill_from` time.
|
2306
|
-
attr_accessor :type
|
2307
|
-
|
2308
|
-
def initialize(line_starts_at: nil, timestamp: nil, type: nil)
|
2309
|
-
@line_starts_at = line_starts_at
|
2310
|
-
@timestamp = timestamp
|
2311
|
-
@type = type
|
2312
|
-
end
|
2313
|
-
end
|
235
|
+
def self.inner_class_types
|
236
|
+
@inner_class_types = { recurring: Recurring, upfront: Upfront }
|
237
|
+
end
|
2314
238
|
|
2315
|
-
|
2316
|
-
|
2317
|
-
|
2318
|
-
|
2319
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
2320
|
-
attr_accessor :interval_count
|
239
|
+
def self.field_remappings
|
240
|
+
@field_remappings = {}
|
241
|
+
end
|
242
|
+
end
|
2321
243
|
|
2322
|
-
|
2323
|
-
|
2324
|
-
|
2325
|
-
|
2326
|
-
|
244
|
+
class FromQuote < Stripe::StripeObject
|
245
|
+
# Whether this quote is a revision of a different quote.
|
246
|
+
attr_reader :is_revision
|
247
|
+
# The quote that was cloned.
|
248
|
+
attr_reader :quote
|
2327
249
|
|
2328
|
-
|
2329
|
-
|
2330
|
-
|
2331
|
-
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
|
2332
|
-
attr_accessor :index
|
250
|
+
def self.inner_class_types
|
251
|
+
@inner_class_types = {}
|
252
|
+
end
|
2333
253
|
|
2334
|
-
|
2335
|
-
|
2336
|
-
|
2337
|
-
|
2338
|
-
end
|
2339
|
-
# Details of the duration over which to bill.
|
2340
|
-
attr_accessor :duration
|
2341
|
-
# Details of a Quote line item from which to bill until.
|
2342
|
-
attr_accessor :line_ends_at
|
2343
|
-
# A precise Unix timestamp.
|
2344
|
-
attr_accessor :timestamp
|
2345
|
-
# The type of method to specify the `bill_until` time.
|
2346
|
-
attr_accessor :type
|
2347
|
-
|
2348
|
-
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil)
|
2349
|
-
@duration = duration
|
2350
|
-
@line_ends_at = line_ends_at
|
2351
|
-
@timestamp = timestamp
|
2352
|
-
@type = type
|
2353
|
-
end
|
2354
|
-
end
|
2355
|
-
# The start of the period to bill from when the Quote is accepted.
|
2356
|
-
attr_accessor :bill_from
|
2357
|
-
# The end of the period to bill until when the Quote is accepted.
|
2358
|
-
attr_accessor :bill_until
|
2359
|
-
|
2360
|
-
def initialize(bill_from: nil, bill_until: nil)
|
2361
|
-
@bill_from = bill_from
|
2362
|
-
@bill_until = bill_until
|
2363
|
-
end
|
2364
|
-
end
|
254
|
+
def self.field_remappings
|
255
|
+
@field_remappings = {}
|
256
|
+
end
|
257
|
+
end
|
2365
258
|
|
2366
|
-
|
2367
|
-
|
2368
|
-
|
259
|
+
class InvoiceSettings < Stripe::StripeObject
|
260
|
+
class Issuer < Stripe::StripeObject
|
261
|
+
# The connected account being referenced when `type` is `account`.
|
262
|
+
attr_reader :account
|
263
|
+
# Type of the account referenced.
|
264
|
+
attr_reader :type
|
2369
265
|
|
2370
|
-
|
2371
|
-
|
2372
|
-
end
|
266
|
+
def self.inner_class_types
|
267
|
+
@inner_class_types = {}
|
2373
268
|
end
|
2374
|
-
|
2375
|
-
|
2376
|
-
|
2377
|
-
attr_accessor :billing_behavior
|
2378
|
-
# When specified as `reset`, the subscription will always start a new billing period when the quote is accepted.
|
2379
|
-
attr_accessor :billing_cycle_anchor
|
2380
|
-
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
|
2381
|
-
attr_accessor :description
|
2382
|
-
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. When updating a subscription, the date of which the subscription will be updated using a subscription schedule. The special value `current_period_end` can be provided to update a subscription at the end of its current period. The `effective_date` is ignored if it is in the past when the quote is accepted.
|
2383
|
-
attr_accessor :effective_date
|
2384
|
-
# Behavior of the subscription schedule and underlying subscription when it ends.
|
2385
|
-
attr_accessor :end_behavior
|
2386
|
-
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
|
2387
|
-
attr_accessor :metadata
|
2388
|
-
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
|
2389
|
-
attr_accessor :prebilling
|
2390
|
-
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
|
2391
|
-
#
|
2392
|
-
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
|
2393
|
-
#
|
2394
|
-
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
|
2395
|
-
#
|
2396
|
-
# Prorations can be disabled by passing `none`.
|
2397
|
-
attr_accessor :proration_behavior
|
2398
|
-
# Integer representing the number of trial period days before the customer is charged for the first time.
|
2399
|
-
attr_accessor :trial_period_days
|
2400
|
-
|
2401
|
-
def initialize(
|
2402
|
-
bill_on_acceptance: nil,
|
2403
|
-
billing_behavior: nil,
|
2404
|
-
billing_cycle_anchor: nil,
|
2405
|
-
description: nil,
|
2406
|
-
effective_date: nil,
|
2407
|
-
end_behavior: nil,
|
2408
|
-
metadata: nil,
|
2409
|
-
prebilling: nil,
|
2410
|
-
proration_behavior: nil,
|
2411
|
-
trial_period_days: nil
|
2412
|
-
)
|
2413
|
-
@bill_on_acceptance = bill_on_acceptance
|
2414
|
-
@billing_behavior = billing_behavior
|
2415
|
-
@billing_cycle_anchor = billing_cycle_anchor
|
2416
|
-
@description = description
|
2417
|
-
@effective_date = effective_date
|
2418
|
-
@end_behavior = end_behavior
|
2419
|
-
@metadata = metadata
|
2420
|
-
@prebilling = prebilling
|
2421
|
-
@proration_behavior = proration_behavior
|
2422
|
-
@trial_period_days = trial_period_days
|
269
|
+
|
270
|
+
def self.field_remappings
|
271
|
+
@field_remappings = {}
|
2423
272
|
end
|
2424
273
|
end
|
274
|
+
# Number of days within which a customer must pay invoices generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
|
275
|
+
attr_reader :days_until_due
|
276
|
+
# Attribute for field issuer
|
277
|
+
attr_reader :issuer
|
2425
278
|
|
2426
|
-
|
2427
|
-
|
2428
|
-
|
2429
|
-
attr_accessor :new_reference
|
2430
|
-
# The ID of the schedule the line applies to.
|
2431
|
-
attr_accessor :subscription_schedule
|
2432
|
-
# Describes whether the quote line is affecting a new schedule or an existing schedule.
|
2433
|
-
attr_accessor :type
|
2434
|
-
|
2435
|
-
def initialize(new_reference: nil, subscription_schedule: nil, type: nil)
|
2436
|
-
@new_reference = new_reference
|
2437
|
-
@subscription_schedule = subscription_schedule
|
2438
|
-
@type = type
|
2439
|
-
end
|
2440
|
-
end
|
279
|
+
def self.inner_class_types
|
280
|
+
@inner_class_types = { issuer: Issuer }
|
281
|
+
end
|
2441
282
|
|
2442
|
-
|
2443
|
-
|
2444
|
-
|
2445
|
-
|
2446
|
-
|
2447
|
-
|
2448
|
-
|
2449
|
-
|
2450
|
-
|
2451
|
-
|
2452
|
-
|
2453
|
-
|
2454
|
-
end
|
2455
|
-
# Details of a Quote line to start the bill period from.
|
2456
|
-
attr_accessor :line_starts_at
|
2457
|
-
# A precise Unix timestamp.
|
2458
|
-
attr_accessor :timestamp
|
2459
|
-
# The type of method to specify the `bill_from` time.
|
2460
|
-
attr_accessor :type
|
2461
|
-
|
2462
|
-
def initialize(line_starts_at: nil, timestamp: nil, type: nil)
|
2463
|
-
@line_starts_at = line_starts_at
|
2464
|
-
@timestamp = timestamp
|
2465
|
-
@type = type
|
2466
|
-
end
|
2467
|
-
end
|
283
|
+
def self.field_remappings
|
284
|
+
@field_remappings = {}
|
285
|
+
end
|
286
|
+
end
|
287
|
+
|
288
|
+
class StatusTransitions < Stripe::StripeObject
|
289
|
+
# The time that the quote was accepted. Measured in seconds since Unix epoch.
|
290
|
+
attr_reader :accepted_at
|
291
|
+
# The time that the quote was canceled. Measured in seconds since Unix epoch.
|
292
|
+
attr_reader :canceled_at
|
293
|
+
# The time that the quote was finalized. Measured in seconds since Unix epoch.
|
294
|
+
attr_reader :finalized_at
|
2468
295
|
|
2469
|
-
|
2470
|
-
|
2471
|
-
|
2472
|
-
attr_accessor :interval
|
2473
|
-
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
|
2474
|
-
attr_accessor :interval_count
|
296
|
+
def self.inner_class_types
|
297
|
+
@inner_class_types = {}
|
298
|
+
end
|
2475
299
|
|
2476
|
-
|
2477
|
-
|
2478
|
-
|
2479
|
-
|
2480
|
-
end
|
300
|
+
def self.field_remappings
|
301
|
+
@field_remappings = {}
|
302
|
+
end
|
303
|
+
end
|
2481
304
|
|
2482
|
-
|
2483
|
-
|
2484
|
-
|
2485
|
-
|
2486
|
-
|
305
|
+
class SubscriptionData < Stripe::StripeObject
|
306
|
+
class BillingMode < Stripe::StripeObject
|
307
|
+
class Flexible < Stripe::StripeObject
|
308
|
+
# Controls how invoices and invoice items display proration amounts and discount amounts.
|
309
|
+
attr_reader :proration_discounts
|
2487
310
|
|
2488
|
-
|
2489
|
-
|
2490
|
-
@index = index
|
2491
|
-
end
|
2492
|
-
end
|
2493
|
-
# Details of the duration over which to bill.
|
2494
|
-
attr_accessor :duration
|
2495
|
-
# Details of a Quote line item from which to bill until.
|
2496
|
-
attr_accessor :line_ends_at
|
2497
|
-
# A precise Unix timestamp.
|
2498
|
-
attr_accessor :timestamp
|
2499
|
-
# The type of method to specify the `bill_until` time.
|
2500
|
-
attr_accessor :type
|
2501
|
-
|
2502
|
-
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil)
|
2503
|
-
@duration = duration
|
2504
|
-
@line_ends_at = line_ends_at
|
2505
|
-
@timestamp = timestamp
|
2506
|
-
@type = type
|
2507
|
-
end
|
311
|
+
def self.inner_class_types
|
312
|
+
@inner_class_types = {}
|
2508
313
|
end
|
2509
|
-
|
2510
|
-
|
2511
|
-
|
2512
|
-
attr_accessor :bill_until
|
2513
|
-
|
2514
|
-
def initialize(bill_from: nil, bill_until: nil)
|
2515
|
-
@bill_from = bill_from
|
2516
|
-
@bill_until = bill_until
|
314
|
+
|
315
|
+
def self.field_remappings
|
316
|
+
@field_remappings = {}
|
2517
317
|
end
|
2518
318
|
end
|
2519
|
-
#
|
2520
|
-
|
2521
|
-
#
|
2522
|
-
|
2523
|
-
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
|
2524
|
-
attr_accessor :billing_behavior
|
2525
|
-
# The customer the Subscription Data override applies to.
|
2526
|
-
attr_accessor :customer
|
2527
|
-
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
|
2528
|
-
attr_accessor :description
|
2529
|
-
# Behavior of the subscription schedule and underlying subscription when it ends.
|
2530
|
-
attr_accessor :end_behavior
|
2531
|
-
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
|
2532
|
-
#
|
2533
|
-
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
|
2534
|
-
#
|
2535
|
-
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
|
2536
|
-
#
|
2537
|
-
# Prorations can be disabled by passing `none`.
|
2538
|
-
attr_accessor :proration_behavior
|
2539
|
-
|
2540
|
-
def initialize(
|
2541
|
-
applies_to: nil,
|
2542
|
-
bill_on_acceptance: nil,
|
2543
|
-
billing_behavior: nil,
|
2544
|
-
customer: nil,
|
2545
|
-
description: nil,
|
2546
|
-
end_behavior: nil,
|
2547
|
-
proration_behavior: nil
|
2548
|
-
)
|
2549
|
-
@applies_to = applies_to
|
2550
|
-
@bill_on_acceptance = bill_on_acceptance
|
2551
|
-
@billing_behavior = billing_behavior
|
2552
|
-
@customer = customer
|
2553
|
-
@description = description
|
2554
|
-
@end_behavior = end_behavior
|
2555
|
-
@proration_behavior = proration_behavior
|
2556
|
-
end
|
2557
|
-
end
|
319
|
+
# Attribute for field flexible
|
320
|
+
attr_reader :flexible
|
321
|
+
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
|
322
|
+
attr_reader :type
|
2558
323
|
|
2559
|
-
|
2560
|
-
|
2561
|
-
attr_accessor :amount
|
2562
|
-
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
|
2563
|
-
attr_accessor :amount_percent
|
2564
|
-
# ID of an existing, connected Stripe account.
|
2565
|
-
attr_accessor :destination
|
2566
|
-
|
2567
|
-
def initialize(amount: nil, amount_percent: nil, destination: nil)
|
2568
|
-
@amount = amount
|
2569
|
-
@amount_percent = amount_percent
|
2570
|
-
@destination = destination
|
324
|
+
def self.inner_class_types
|
325
|
+
@inner_class_types = { flexible: Flexible }
|
2571
326
|
end
|
2572
|
-
end
|
2573
|
-
# Set to true to allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
|
2574
|
-
attr_accessor :allow_backdated_lines
|
2575
|
-
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
|
2576
|
-
attr_accessor :application_fee_amount
|
2577
|
-
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
|
2578
|
-
attr_accessor :application_fee_percent
|
2579
|
-
# Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
|
2580
|
-
attr_accessor :automatic_tax
|
2581
|
-
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
|
2582
|
-
attr_accessor :collection_method
|
2583
|
-
# The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
|
2584
|
-
attr_accessor :customer
|
2585
|
-
# The account for which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
|
2586
|
-
attr_accessor :customer_account
|
2587
|
-
# The tax rates that will apply to any line item that does not have `tax_rates` set.
|
2588
|
-
attr_accessor :default_tax_rates
|
2589
|
-
# A description that will be displayed on the quote PDF.
|
2590
|
-
attr_accessor :description
|
2591
|
-
# The discounts applied to the quote.
|
2592
|
-
attr_accessor :discounts
|
2593
|
-
# Specifies which fields in the response should be expanded.
|
2594
|
-
attr_accessor :expand
|
2595
|
-
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
|
2596
|
-
attr_accessor :expires_at
|
2597
|
-
# A footer that will be displayed on the quote PDF.
|
2598
|
-
attr_accessor :footer
|
2599
|
-
# A header that will be displayed on the quote PDF.
|
2600
|
-
attr_accessor :header
|
2601
|
-
# All invoices will be billed using the specified settings.
|
2602
|
-
attr_accessor :invoice_settings
|
2603
|
-
# A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
|
2604
|
-
attr_accessor :line_items
|
2605
|
-
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
|
2606
|
-
attr_accessor :lines
|
2607
|
-
# 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`.
|
2608
|
-
attr_accessor :metadata
|
2609
|
-
# The account on behalf of which to charge.
|
2610
|
-
attr_accessor :on_behalf_of
|
2611
|
-
# When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
|
2612
|
-
attr_accessor :subscription_data
|
2613
|
-
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
|
2614
|
-
attr_accessor :subscription_data_overrides
|
2615
|
-
# The data with which to automatically create a Transfer for each of the invoices.
|
2616
|
-
attr_accessor :transfer_data
|
2617
|
-
|
2618
|
-
def initialize(
|
2619
|
-
allow_backdated_lines: nil,
|
2620
|
-
application_fee_amount: nil,
|
2621
|
-
application_fee_percent: nil,
|
2622
|
-
automatic_tax: nil,
|
2623
|
-
collection_method: nil,
|
2624
|
-
customer: nil,
|
2625
|
-
customer_account: nil,
|
2626
|
-
default_tax_rates: nil,
|
2627
|
-
description: nil,
|
2628
|
-
discounts: nil,
|
2629
|
-
expand: nil,
|
2630
|
-
expires_at: nil,
|
2631
|
-
footer: nil,
|
2632
|
-
header: nil,
|
2633
|
-
invoice_settings: nil,
|
2634
|
-
line_items: nil,
|
2635
|
-
lines: nil,
|
2636
|
-
metadata: nil,
|
2637
|
-
on_behalf_of: nil,
|
2638
|
-
subscription_data: nil,
|
2639
|
-
subscription_data_overrides: nil,
|
2640
|
-
transfer_data: nil
|
2641
|
-
)
|
2642
|
-
@allow_backdated_lines = allow_backdated_lines
|
2643
|
-
@application_fee_amount = application_fee_amount
|
2644
|
-
@application_fee_percent = application_fee_percent
|
2645
|
-
@automatic_tax = automatic_tax
|
2646
|
-
@collection_method = collection_method
|
2647
|
-
@customer = customer
|
2648
|
-
@customer_account = customer_account
|
2649
|
-
@default_tax_rates = default_tax_rates
|
2650
|
-
@description = description
|
2651
|
-
@discounts = discounts
|
2652
|
-
@expand = expand
|
2653
|
-
@expires_at = expires_at
|
2654
|
-
@footer = footer
|
2655
|
-
@header = header
|
2656
|
-
@invoice_settings = invoice_settings
|
2657
|
-
@line_items = line_items
|
2658
|
-
@lines = lines
|
2659
|
-
@metadata = metadata
|
2660
|
-
@on_behalf_of = on_behalf_of
|
2661
|
-
@subscription_data = subscription_data
|
2662
|
-
@subscription_data_overrides = subscription_data_overrides
|
2663
|
-
@transfer_data = transfer_data
|
2664
|
-
end
|
2665
|
-
end
|
2666
327
|
|
2667
|
-
|
2668
|
-
|
2669
|
-
|
2670
|
-
# Specifies which fields in the response should be expanded.
|
2671
|
-
attr_accessor :expand
|
2672
|
-
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
2673
|
-
attr_accessor :limit
|
2674
|
-
# 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.
|
2675
|
-
attr_accessor :starting_after
|
2676
|
-
|
2677
|
-
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil)
|
2678
|
-
@ending_before = ending_before
|
2679
|
-
@expand = expand
|
2680
|
-
@limit = limit
|
2681
|
-
@starting_after = starting_after
|
328
|
+
def self.field_remappings
|
329
|
+
@field_remappings = {}
|
330
|
+
end
|
2682
331
|
end
|
2683
|
-
|
332
|
+
# The billing mode of the quote.
|
333
|
+
attr_reader :billing_mode
|
334
|
+
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
|
335
|
+
attr_reader :description
|
336
|
+
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. This date is ignored if it is in the past when the quote is accepted. Measured in seconds since the Unix epoch.
|
337
|
+
attr_reader :effective_date
|
338
|
+
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
|
339
|
+
attr_reader :metadata
|
340
|
+
# Integer representing the number of trial period days before the customer is charged for the first time.
|
341
|
+
attr_reader :trial_period_days
|
2684
342
|
|
2685
|
-
|
2686
|
-
|
2687
|
-
attr_accessor :ending_before
|
2688
|
-
# Specifies which fields in the response should be expanded.
|
2689
|
-
attr_accessor :expand
|
2690
|
-
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
2691
|
-
attr_accessor :limit
|
2692
|
-
# 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.
|
2693
|
-
attr_accessor :starting_after
|
2694
|
-
|
2695
|
-
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil)
|
2696
|
-
@ending_before = ending_before
|
2697
|
-
@expand = expand
|
2698
|
-
@limit = limit
|
2699
|
-
@starting_after = starting_after
|
343
|
+
def self.inner_class_types
|
344
|
+
@inner_class_types = { billing_mode: BillingMode }
|
2700
345
|
end
|
2701
|
-
end
|
2702
346
|
|
2703
|
-
|
2704
|
-
|
2705
|
-
attr_accessor :ending_before
|
2706
|
-
# Specifies which fields in the response should be expanded.
|
2707
|
-
attr_accessor :expand
|
2708
|
-
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
2709
|
-
attr_accessor :limit
|
2710
|
-
# 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.
|
2711
|
-
attr_accessor :starting_after
|
2712
|
-
|
2713
|
-
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil)
|
2714
|
-
@ending_before = ending_before
|
2715
|
-
@expand = expand
|
2716
|
-
@limit = limit
|
2717
|
-
@starting_after = starting_after
|
347
|
+
def self.field_remappings
|
348
|
+
@field_remappings = {}
|
2718
349
|
end
|
2719
350
|
end
|
2720
351
|
|
2721
|
-
class
|
2722
|
-
|
2723
|
-
|
352
|
+
class TotalDetails < Stripe::StripeObject
|
353
|
+
class Breakdown < Stripe::StripeObject
|
354
|
+
class Discount < Stripe::StripeObject
|
355
|
+
# The amount discounted.
|
356
|
+
attr_reader :amount
|
357
|
+
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
|
358
|
+
# It contains information about when the discount began, when it will end, and what it is applied to.
|
359
|
+
#
|
360
|
+
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
|
361
|
+
attr_reader :discount
|
2724
362
|
|
2725
|
-
|
2726
|
-
|
2727
|
-
|
2728
|
-
end
|
363
|
+
def self.inner_class_types
|
364
|
+
@inner_class_types = {}
|
365
|
+
end
|
2729
366
|
|
2730
|
-
|
2731
|
-
|
2732
|
-
|
367
|
+
def self.field_remappings
|
368
|
+
@field_remappings = {}
|
369
|
+
end
|
370
|
+
end
|
2733
371
|
|
2734
|
-
|
2735
|
-
|
2736
|
-
|
2737
|
-
|
372
|
+
class Tax < Stripe::StripeObject
|
373
|
+
# Amount of tax applied for this rate.
|
374
|
+
attr_reader :amount
|
375
|
+
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
|
376
|
+
#
|
377
|
+
# Related guide: [Tax rates](/billing/taxes/tax-rates)
|
378
|
+
attr_reader :rate
|
379
|
+
# The reasoning behind this tax, for example, if the product is tax exempt. The possible values for this field may be extended as new tax rules are supported.
|
380
|
+
attr_reader :taxability_reason
|
381
|
+
# The amount on which tax is calculated, in cents (or local equivalent).
|
382
|
+
attr_reader :taxable_amount
|
2738
383
|
|
2739
|
-
|
2740
|
-
|
2741
|
-
|
2742
|
-
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
|
2743
|
-
attr_accessor :expires_at
|
384
|
+
def self.inner_class_types
|
385
|
+
@inner_class_types = {}
|
386
|
+
end
|
2744
387
|
|
2745
|
-
|
2746
|
-
|
2747
|
-
|
2748
|
-
|
2749
|
-
|
388
|
+
def self.field_remappings
|
389
|
+
@field_remappings = {}
|
390
|
+
end
|
391
|
+
end
|
392
|
+
# The aggregated discounts.
|
393
|
+
attr_reader :discounts
|
394
|
+
# The aggregated tax amounts by rate.
|
395
|
+
attr_reader :taxes
|
2750
396
|
|
2751
|
-
|
2752
|
-
|
2753
|
-
|
397
|
+
def self.inner_class_types
|
398
|
+
@inner_class_types = { discounts: Discount, taxes: Tax }
|
399
|
+
end
|
2754
400
|
|
2755
|
-
|
2756
|
-
|
401
|
+
def self.field_remappings
|
402
|
+
@field_remappings = {}
|
403
|
+
end
|
2757
404
|
end
|
2758
|
-
|
2759
|
-
|
2760
|
-
|
2761
|
-
|
2762
|
-
|
2763
|
-
|
2764
|
-
|
405
|
+
# This is the sum of all the discounts.
|
406
|
+
attr_reader :amount_discount
|
407
|
+
# This is the sum of all the shipping amounts.
|
408
|
+
attr_reader :amount_shipping
|
409
|
+
# This is the sum of all the tax amounts.
|
410
|
+
attr_reader :amount_tax
|
411
|
+
# Attribute for field breakdown
|
412
|
+
attr_reader :breakdown
|
2765
413
|
|
2766
|
-
def
|
2767
|
-
@
|
2768
|
-
@reason = reason
|
414
|
+
def self.inner_class_types
|
415
|
+
@inner_class_types = { breakdown: Breakdown }
|
2769
416
|
end
|
2770
|
-
end
|
2771
|
-
|
2772
|
-
class ReestimateParams < Stripe::RequestParams
|
2773
|
-
# Specifies which fields in the response should be expanded.
|
2774
|
-
attr_accessor :expand
|
2775
417
|
|
2776
|
-
def
|
2777
|
-
@
|
418
|
+
def self.field_remappings
|
419
|
+
@field_remappings = {}
|
2778
420
|
end
|
2779
421
|
end
|
2780
422
|
|
2781
|
-
class
|
2782
|
-
#
|
2783
|
-
|
423
|
+
class TransferData < Stripe::StripeObject
|
424
|
+
# The amount in cents (or local equivalent) that will be transferred to the destination account when the invoice is paid. By default, the entire amount is transferred to the destination.
|
425
|
+
attr_reader :amount
|
426
|
+
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount will be transferred to the destination.
|
427
|
+
attr_reader :amount_percent
|
428
|
+
# The account where funds from the payment will be transferred to upon payment success.
|
429
|
+
attr_reader :destination
|
2784
430
|
|
2785
|
-
def
|
2786
|
-
@
|
431
|
+
def self.inner_class_types
|
432
|
+
@inner_class_types = {}
|
2787
433
|
end
|
2788
|
-
end
|
2789
434
|
|
2790
|
-
|
2791
|
-
|
2792
|
-
attr_accessor :ending_before
|
2793
|
-
# Specifies which fields in the response should be expanded.
|
2794
|
-
attr_accessor :expand
|
2795
|
-
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
|
2796
|
-
attr_accessor :limit
|
2797
|
-
# 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.
|
2798
|
-
attr_accessor :starting_after
|
2799
|
-
|
2800
|
-
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil)
|
2801
|
-
@ending_before = ending_before
|
2802
|
-
@expand = expand
|
2803
|
-
@limit = limit
|
2804
|
-
@starting_after = starting_after
|
435
|
+
def self.field_remappings
|
436
|
+
@field_remappings = {}
|
2805
437
|
end
|
2806
438
|
end
|
2807
|
-
# Allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
|
2808
|
-
attr_reader :allow_backdated_lines
|
2809
439
|
# Total before any discounts or taxes are applied.
|
2810
440
|
attr_reader :amount_subtotal
|
2811
441
|
# Total after discounts and taxes are applied.
|
@@ -2828,8 +458,6 @@ module Stripe
|
|
2828
458
|
attr_reader :currency
|
2829
459
|
# The customer which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
|
2830
460
|
attr_reader :customer
|
2831
|
-
# The account which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
|
2832
|
-
attr_reader :customer_account
|
2833
461
|
# The tax rates applied to this quote.
|
2834
462
|
attr_reader :default_tax_rates
|
2835
463
|
# A description that will be displayed on the quote PDF.
|
@@ -2852,8 +480,6 @@ module Stripe
|
|
2852
480
|
attr_reader :invoice_settings
|
2853
481
|
# A list of items the customer is being quoted for.
|
2854
482
|
attr_reader :line_items
|
2855
|
-
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
|
2856
|
-
attr_reader :lines
|
2857
483
|
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
|
2858
484
|
attr_reader :livemode
|
2859
485
|
# 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.
|
@@ -2866,20 +492,14 @@ module Stripe
|
|
2866
492
|
attr_reader :on_behalf_of
|
2867
493
|
# The status of the quote.
|
2868
494
|
attr_reader :status
|
2869
|
-
# Details on when and why a quote has been marked as stale or canceled.
|
2870
|
-
attr_reader :status_details
|
2871
495
|
# Attribute for field status_transitions
|
2872
496
|
attr_reader :status_transitions
|
2873
497
|
# The subscription that was created or updated from this quote.
|
2874
498
|
attr_reader :subscription
|
2875
499
|
# Attribute for field subscription_data
|
2876
500
|
attr_reader :subscription_data
|
2877
|
-
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
|
2878
|
-
attr_reader :subscription_data_overrides
|
2879
501
|
# The subscription schedule that was created or updated from this quote.
|
2880
502
|
attr_reader :subscription_schedule
|
2881
|
-
# The subscription schedules that were created or updated from this quote.
|
2882
|
-
attr_reader :subscription_schedules
|
2883
503
|
# ID of the test clock this quote belongs to.
|
2884
504
|
attr_reader :test_clock
|
2885
505
|
# Attribute for field total_details
|
@@ -2997,86 +617,6 @@ module Stripe
|
|
2997
617
|
)
|
2998
618
|
end
|
2999
619
|
|
3000
|
-
# Retrieves a paginated list of lines for a quote. These lines describe changes that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
|
3001
|
-
def list_lines(params = {}, opts = {})
|
3002
|
-
request_stripe_object(
|
3003
|
-
method: :get,
|
3004
|
-
path: format("/v1/quotes/%<quote>s/lines", { quote: CGI.escape(self["id"]) }),
|
3005
|
-
params: params,
|
3006
|
-
opts: opts
|
3007
|
-
)
|
3008
|
-
end
|
3009
|
-
|
3010
|
-
# Retrieves a paginated list of lines for a quote. These lines describe changes that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
|
3011
|
-
def self.list_lines(quote, params = {}, opts = {})
|
3012
|
-
request_stripe_object(
|
3013
|
-
method: :get,
|
3014
|
-
path: format("/v1/quotes/%<quote>s/lines", { quote: CGI.escape(quote) }),
|
3015
|
-
params: params,
|
3016
|
-
opts: opts
|
3017
|
-
)
|
3018
|
-
end
|
3019
|
-
|
3020
|
-
# Preview the invoice line items that would be generated by accepting the quote.
|
3021
|
-
def list_preview_invoice_lines(preview_invoice, params = {}, opts = {})
|
3022
|
-
request_stripe_object(
|
3023
|
-
method: :get,
|
3024
|
-
path: format("/v1/quotes/%<quote>s/preview_invoices/%<preview_invoice>s/lines", { quote: CGI.escape(self["id"]), preview_invoice: CGI.escape(preview_invoice) }),
|
3025
|
-
params: params,
|
3026
|
-
opts: opts
|
3027
|
-
)
|
3028
|
-
end
|
3029
|
-
|
3030
|
-
# Preview the invoice line items that would be generated by accepting the quote.
|
3031
|
-
def self.list_preview_invoice_lines(quote, preview_invoice, params = {}, opts = {})
|
3032
|
-
request_stripe_object(
|
3033
|
-
method: :get,
|
3034
|
-
path: format("/v1/quotes/%<quote>s/preview_invoices/%<preview_invoice>s/lines", { quote: CGI.escape(quote), preview_invoice: CGI.escape(preview_invoice) }),
|
3035
|
-
params: params,
|
3036
|
-
opts: opts
|
3037
|
-
)
|
3038
|
-
end
|
3039
|
-
|
3040
|
-
# Converts a stale quote to draft.
|
3041
|
-
def mark_draft(params = {}, opts = {})
|
3042
|
-
request_stripe_object(
|
3043
|
-
method: :post,
|
3044
|
-
path: format("/v1/quotes/%<quote>s/mark_draft", { quote: CGI.escape(self["id"]) }),
|
3045
|
-
params: params,
|
3046
|
-
opts: opts
|
3047
|
-
)
|
3048
|
-
end
|
3049
|
-
|
3050
|
-
# Converts a stale quote to draft.
|
3051
|
-
def self.mark_draft(quote, params = {}, opts = {})
|
3052
|
-
request_stripe_object(
|
3053
|
-
method: :post,
|
3054
|
-
path: format("/v1/quotes/%<quote>s/mark_draft", { quote: CGI.escape(quote) }),
|
3055
|
-
params: params,
|
3056
|
-
opts: opts
|
3057
|
-
)
|
3058
|
-
end
|
3059
|
-
|
3060
|
-
# Converts a draft or open quote to stale.
|
3061
|
-
def mark_stale(params = {}, opts = {})
|
3062
|
-
request_stripe_object(
|
3063
|
-
method: :post,
|
3064
|
-
path: format("/v1/quotes/%<quote>s/mark_stale", { quote: CGI.escape(self["id"]) }),
|
3065
|
-
params: params,
|
3066
|
-
opts: opts
|
3067
|
-
)
|
3068
|
-
end
|
3069
|
-
|
3070
|
-
# Converts a draft or open quote to stale.
|
3071
|
-
def self.mark_stale(quote, params = {}, opts = {})
|
3072
|
-
request_stripe_object(
|
3073
|
-
method: :post,
|
3074
|
-
path: format("/v1/quotes/%<quote>s/mark_stale", { quote: CGI.escape(quote) }),
|
3075
|
-
params: params,
|
3076
|
-
opts: opts
|
3077
|
-
)
|
3078
|
-
end
|
3079
|
-
|
3080
620
|
# Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf)
|
3081
621
|
def pdf(params = {}, opts = {}, &read_body_chunk_block)
|
3082
622
|
opts = { api_base: APIRequestor.active_requestor.config.uploads_base }.merge(opts)
|
@@ -3103,34 +643,31 @@ module Stripe
|
|
3103
643
|
)
|
3104
644
|
end
|
3105
645
|
|
3106
|
-
#
|
3107
|
-
def
|
646
|
+
# A quote models prices and services for a customer.
|
647
|
+
def self.update(quote, params = {}, opts = {})
|
3108
648
|
request_stripe_object(
|
3109
649
|
method: :post,
|
3110
|
-
path: format("/v1/quotes/%<quote>s
|
650
|
+
path: format("/v1/quotes/%<quote>s", { quote: CGI.escape(quote) }),
|
3111
651
|
params: params,
|
3112
652
|
opts: opts
|
3113
653
|
)
|
3114
654
|
end
|
3115
655
|
|
3116
|
-
|
3117
|
-
|
3118
|
-
|
3119
|
-
|
3120
|
-
|
3121
|
-
|
3122
|
-
|
3123
|
-
|
656
|
+
def self.inner_class_types
|
657
|
+
@inner_class_types = {
|
658
|
+
automatic_tax: AutomaticTax,
|
659
|
+
computed: Computed,
|
660
|
+
from_quote: FromQuote,
|
661
|
+
invoice_settings: InvoiceSettings,
|
662
|
+
status_transitions: StatusTransitions,
|
663
|
+
subscription_data: SubscriptionData,
|
664
|
+
total_details: TotalDetails,
|
665
|
+
transfer_data: TransferData,
|
666
|
+
}
|
3124
667
|
end
|
3125
668
|
|
3126
|
-
|
3127
|
-
|
3128
|
-
request_stripe_object(
|
3129
|
-
method: :post,
|
3130
|
-
path: format("/v1/quotes/%<quote>s", { quote: CGI.escape(quote) }),
|
3131
|
-
params: params,
|
3132
|
-
opts: opts
|
3133
|
-
)
|
669
|
+
def self.field_remappings
|
670
|
+
@field_remappings = {}
|
3134
671
|
end
|
3135
672
|
end
|
3136
673
|
end
|