stripe 5.28.0 → 8.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +286 -0
- data/Gemfile +5 -3
- data/Makefile +13 -0
- data/OPENAPI_VERSION +1 -0
- data/README.md +43 -5
- data/VERSION +1 -1
- data/lib/data/ca-certificates.crt +1241 -1937
- data/lib/stripe/api_operations/create.rb +6 -2
- data/lib/stripe/api_operations/delete.rb +12 -7
- data/lib/stripe/api_operations/list.rb +6 -9
- data/lib/stripe/api_operations/nested_resource.rb +62 -34
- data/lib/stripe/api_operations/request.rb +45 -2
- data/lib/stripe/api_operations/save.rb +13 -3
- data/lib/stripe/api_operations/search.rb +16 -0
- data/lib/stripe/api_resource.rb +11 -18
- data/lib/stripe/api_resource_test_helpers.rb +49 -0
- data/lib/stripe/api_version.rb +8 -0
- data/lib/stripe/connection_manager.rb +49 -11
- data/lib/stripe/error_object.rb +2 -3
- data/lib/stripe/instrumentation.rb +46 -6
- data/lib/stripe/oauth.rb +4 -3
- data/lib/stripe/object_types.rb +36 -10
- data/lib/stripe/resources/account.rb +39 -17
- data/lib/stripe/resources/account_link.rb +4 -0
- data/lib/stripe/resources/application_fee_refund.rb +7 -1
- data/lib/stripe/resources/apps/secret.rb +40 -0
- data/lib/stripe/resources/balance.rb +11 -0
- data/lib/stripe/resources/balance_transaction.rb +4 -0
- data/lib/stripe/resources/bank_account.rb +7 -0
- data/lib/stripe/resources/billing_portal/configuration.rb +15 -0
- data/lib/stripe/resources/billing_portal/session.rb +14 -0
- data/lib/stripe/resources/capability.rb +5 -1
- data/lib/stripe/resources/card.rb +6 -3
- data/lib/stripe/resources/cash_balance.rb +23 -0
- data/lib/stripe/resources/charge.rb +23 -3
- data/lib/stripe/resources/checkout/session.rb +49 -2
- data/lib/stripe/resources/country_spec.rb +6 -0
- data/lib/stripe/resources/coupon.rb +3 -0
- data/lib/stripe/resources/credit_note.rb +27 -9
- data/lib/stripe/resources/credit_note_line_item.rb +2 -0
- data/lib/stripe/resources/customer.rb +132 -4
- data/lib/stripe/resources/customer_balance_transaction.rb +9 -2
- data/lib/stripe/resources/customer_cash_balance_transaction.rb +14 -0
- data/lib/stripe/resources/discount.rb +5 -0
- data/lib/stripe/resources/dispute.rb +17 -3
- data/lib/stripe/resources/event.rb +29 -0
- data/lib/stripe/resources/exchange_rate.rb +11 -0
- data/lib/stripe/resources/file.rb +9 -1
- data/lib/stripe/resources/file_link.rb +3 -0
- data/lib/stripe/resources/financial_connections/account.rb +67 -0
- data/lib/stripe/resources/financial_connections/account_owner.rb +11 -0
- data/lib/stripe/resources/financial_connections/account_ownership.rb +11 -0
- data/lib/stripe/resources/financial_connections/session.rb +13 -0
- data/lib/stripe/resources/funding_instructions.rb +21 -0
- data/lib/stripe/resources/identity/verification_report.rb +23 -0
- data/lib/stripe/resources/identity/verification_session.rb +61 -0
- data/lib/stripe/resources/invoice.rb +105 -17
- data/lib/stripe/resources/invoice_item.rb +11 -0
- data/lib/stripe/resources/invoice_line_item.rb +1 -0
- data/lib/stripe/resources/issuing/authorization.rb +25 -5
- data/lib/stripe/resources/issuing/card.rb +78 -8
- data/lib/stripe/resources/issuing/cardholder.rb +3 -0
- data/lib/stripe/resources/issuing/dispute.rb +13 -3
- data/lib/stripe/resources/issuing/transaction.rb +5 -0
- data/lib/stripe/resources/line_item.rb +2 -0
- data/lib/stripe/resources/login_link.rb +2 -0
- data/lib/stripe/resources/mandate.rb +1 -0
- data/lib/stripe/resources/payment_intent.rb +103 -6
- data/lib/stripe/resources/payment_link.rb +35 -0
- data/lib/stripe/resources/payment_method.rb +25 -5
- data/lib/stripe/resources/payout.rb +28 -5
- data/lib/stripe/resources/person.rb +7 -0
- data/lib/stripe/resources/plan.rb +8 -0
- data/lib/stripe/resources/price.rb +15 -0
- data/lib/stripe/resources/product.rb +17 -0
- data/lib/stripe/resources/promotion_code.rb +2 -0
- data/lib/stripe/resources/quote.rb +128 -0
- data/lib/stripe/resources/radar/early_fraud_warning.rb +4 -0
- data/lib/stripe/resources/radar/value_list.rb +3 -0
- data/lib/stripe/resources/radar/value_list_item.rb +3 -0
- data/lib/stripe/resources/refund.rb +49 -0
- data/lib/stripe/resources/reporting/report_run.rb +8 -0
- data/lib/stripe/resources/reporting/report_type.rb +8 -1
- data/lib/stripe/resources/reversal.rb +16 -2
- data/lib/stripe/resources/review.rb +14 -3
- data/lib/stripe/resources/setup_attempt.rb +4 -0
- data/lib/stripe/resources/setup_intent.rb +60 -5
- data/lib/stripe/resources/shipping_rate.rb +14 -0
- data/lib/stripe/resources/sigma/scheduled_query_run.rb +4 -0
- data/lib/stripe/resources/source.rb +26 -6
- data/lib/stripe/resources/source_transaction.rb +5 -0
- data/lib/stripe/resources/subscription.rb +57 -3
- data/lib/stripe/resources/subscription_item.rb +2 -7
- data/lib/stripe/resources/subscription_schedule.rb +23 -5
- data/lib/stripe/resources/tax/calculation.rb +33 -0
- data/lib/stripe/resources/tax/calculation_line_item.rb +10 -0
- data/lib/stripe/resources/tax/settings.rb +15 -0
- data/lib/stripe/resources/tax/transaction.rb +49 -0
- data/lib/stripe/resources/tax/transaction_line_item.rb +10 -0
- data/lib/stripe/resources/tax_code.rb +11 -0
- data/lib/stripe/resources/tax_id.rb +5 -0
- data/lib/stripe/resources/tax_rate.rb +3 -0
- data/lib/stripe/resources/terminal/configuration.rb +16 -0
- data/lib/stripe/resources/terminal/connection_token.rb +3 -0
- data/lib/stripe/resources/terminal/location.rb +3 -0
- data/lib/stripe/resources/terminal/reader.rb +119 -0
- data/lib/stripe/resources/test_helpers/test_clock.rb +35 -0
- data/lib/stripe/resources/token.rb +20 -0
- data/lib/stripe/resources/topup.rb +15 -3
- data/lib/stripe/resources/transfer.rb +10 -11
- data/lib/stripe/resources/treasury/credit_reversal.rb +14 -0
- data/lib/stripe/resources/treasury/debit_reversal.rb +14 -0
- data/lib/stripe/resources/treasury/financial_account.rb +52 -0
- data/lib/stripe/resources/treasury/financial_account_features.rb +12 -0
- data/lib/stripe/resources/treasury/inbound_transfer.rb +94 -0
- data/lib/stripe/resources/treasury/outbound_payment.rb +96 -0
- data/lib/stripe/resources/treasury/outbound_transfer.rb +100 -0
- data/lib/stripe/resources/treasury/received_credit.rb +30 -0
- data/lib/stripe/resources/treasury/received_debit.rb +30 -0
- data/lib/stripe/resources/treasury/transaction.rb +13 -0
- data/lib/stripe/resources/treasury/transaction_entry.rb +17 -0
- data/lib/stripe/resources/usage_record.rb +5 -0
- data/lib/stripe/resources/usage_record_summary.rb +1 -0
- data/lib/stripe/resources/webhook_endpoint.rb +7 -0
- data/lib/stripe/resources.rb +34 -10
- data/lib/stripe/search_result_object.rb +86 -0
- data/lib/stripe/stripe_client.rb +267 -121
- data/lib/stripe/stripe_configuration.rb +29 -10
- data/lib/stripe/stripe_object.rb +25 -2
- data/lib/stripe/stripe_response.rb +80 -52
- data/lib/stripe/util.rb +100 -9
- data/lib/stripe/version.rb +1 -1
- data/lib/stripe.rb +27 -23
- data/stripe.gemspec +12 -5
- metadata +46 -204
- data/.editorconfig +0 -10
- data/.gitattributes +0 -4
- data/.github/ISSUE_TEMPLATE.md +0 -5
- data/.gitignore +0 -8
- data/.rubocop.yml +0 -80
- data/.rubocop_todo.yml +0 -33
- data/.travis.yml +0 -38
- data/.vscode/extensions.json +0 -7
- data/.vscode/settings.json +0 -8
- data/lib/stripe/resources/bitcoin_receiver.rb +0 -24
- data/lib/stripe/resources/bitcoin_transaction.rb +0 -15
- data/lib/stripe/resources/issuing/card_details.rb +0 -9
- data/lib/stripe/resources/order.rb +0 -33
- data/lib/stripe/resources/order_return.rb +0 -10
- data/lib/stripe/resources/recipient.rb +0 -14
- data/lib/stripe/resources/sku.rb +0 -13
- data/lib/stripe/resources/three_d_secure.rb +0 -14
- data/test/openapi/README.md +0 -9
- data/test/stripe/account_link_test.rb +0 -18
- data/test/stripe/account_test.rb +0 -412
- data/test/stripe/alipay_account_test.rb +0 -37
- data/test/stripe/api_operations_test.rb +0 -80
- data/test/stripe/api_resource_test.rb +0 -646
- data/test/stripe/apple_pay_domain_test.rb +0 -46
- data/test/stripe/application_fee_refund_test.rb +0 -37
- data/test/stripe/application_fee_test.rb +0 -58
- data/test/stripe/balance_test.rb +0 -13
- data/test/stripe/balance_transaction_test.rb +0 -20
- data/test/stripe/bank_account_test.rb +0 -36
- data/test/stripe/billing_portal/session_test.rb +0 -18
- data/test/stripe/capability_test.rb +0 -45
- data/test/stripe/charge_test.rb +0 -64
- data/test/stripe/checkout/session_test.rb +0 -53
- data/test/stripe/connection_manager_test.rb +0 -167
- data/test/stripe/country_spec_test.rb +0 -20
- data/test/stripe/coupon_test.rb +0 -61
- data/test/stripe/credit_note_test.rb +0 -90
- data/test/stripe/customer_balance_transaction_test.rb +0 -37
- data/test/stripe/customer_card_test.rb +0 -48
- data/test/stripe/customer_test.rb +0 -226
- data/test/stripe/dispute_test.rb +0 -51
- data/test/stripe/ephemeral_key_test.rb +0 -93
- data/test/stripe/errors_test.rb +0 -53
- data/test/stripe/exchange_rate_test.rb +0 -20
- data/test/stripe/file_link_test.rb +0 -41
- data/test/stripe/file_test.rb +0 -87
- data/test/stripe/instrumentation_test.rb +0 -74
- data/test/stripe/invoice_item_test.rb +0 -66
- data/test/stripe/invoice_line_item_test.rb +0 -8
- data/test/stripe/invoice_test.rb +0 -229
- data/test/stripe/issuing/authorization_test.rb +0 -72
- data/test/stripe/issuing/card_test.rb +0 -74
- data/test/stripe/issuing/cardholder_test.rb +0 -53
- data/test/stripe/issuing/dispute_test.rb +0 -54
- data/test/stripe/issuing/transaction_test.rb +0 -48
- data/test/stripe/list_object_test.rb +0 -202
- data/test/stripe/login_link_test.rb +0 -37
- data/test/stripe/mandate_test.rb +0 -14
- data/test/stripe/multipart_encoder_test.rb +0 -130
- data/test/stripe/oauth_test.rb +0 -104
- data/test/stripe/order_return_test.rb +0 -21
- data/test/stripe/order_test.rb +0 -82
- data/test/stripe/payment_intent_test.rb +0 -107
- data/test/stripe/payment_method_test.rb +0 -84
- data/test/stripe/payout_test.rb +0 -72
- data/test/stripe/person_test.rb +0 -46
- data/test/stripe/plan_test.rb +0 -98
- data/test/stripe/price_test.rb +0 -48
- data/test/stripe/product_test.rb +0 -58
- data/test/stripe/promotion_code_test.rb +0 -42
- data/test/stripe/radar/early_fraud_warning_test.rb +0 -22
- data/test/stripe/radar/value_list_item_test.rb +0 -48
- data/test/stripe/radar/value_list_test.rb +0 -61
- data/test/stripe/recipient_test.rb +0 -62
- data/test/stripe/refund_test.rb +0 -39
- data/test/stripe/reporting/report_run_test.rb +0 -33
- data/test/stripe/reporting/report_type_test.rb +0 -22
- data/test/stripe/reversal_test.rb +0 -43
- data/test/stripe/review_test.rb +0 -27
- data/test/stripe/setup_attempt_test.rb +0 -16
- data/test/stripe/setup_intent_test.rb +0 -84
- data/test/stripe/sigma/scheduled_query_run_test.rb +0 -22
- data/test/stripe/sku_test.rb +0 -60
- data/test/stripe/source_test.rb +0 -119
- data/test/stripe/stripe_client_test.rb +0 -1291
- data/test/stripe/stripe_configuration_test.rb +0 -131
- data/test/stripe/stripe_object_test.rb +0 -500
- data/test/stripe/stripe_response_test.rb +0 -95
- data/test/stripe/subscription_item_test.rb +0 -84
- data/test/stripe/subscription_schedule_test.rb +0 -82
- data/test/stripe/subscription_test.rb +0 -80
- data/test/stripe/tax_id_test.rb +0 -31
- data/test/stripe/tax_rate_test.rb +0 -43
- data/test/stripe/terminal/connection_token_test.rb +0 -16
- data/test/stripe/terminal/location_test.rb +0 -68
- data/test/stripe/terminal/reader_test.rb +0 -62
- data/test/stripe/three_d_secure_test.rb +0 -23
- data/test/stripe/topup_test.rb +0 -62
- data/test/stripe/transfer_test.rb +0 -88
- data/test/stripe/usage_record_summary_test.rb +0 -29
- data/test/stripe/util_test.rb +0 -402
- data/test/stripe/webhook_endpoint_test.rb +0 -59
- data/test/stripe/webhook_test.rb +0 -135
- data/test/stripe_mock.rb +0 -78
- data/test/stripe_test.rb +0 -132
- data/test/test_data.rb +0 -61
- data/test/test_helper.rb +0 -77
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ff2d744f7713eb43a337ea7069114c02fa4a9ec886efc5e69332661ff9b90f7d
|
4
|
+
data.tar.gz: a81af3893eb05270691d307ed0caa132a2ce5fa6b50497840f7d35606dbb7b45
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 951d8c44a5ed2d161946b139980de3290731d58fecd3ec3118604df28e88ca4a0d30c015fef53990a7cef665e3529b129cee34862f6c05e42865184c249966ef
|
7
|
+
data.tar.gz: 7aacbdc98ce6c65b9f345d1f28aed3bcc149d6e2422f8688e2de89dd6b874884a2426018bb391fdb262bac77bd910e4bd896fdfbe83a707ddafd29c82e0d66f6
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,291 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## 8.7.0 - 2023-08-10
|
4
|
+
* [#1256](https://github.com/stripe/stripe-ruby/pull/1256) Update generated code
|
5
|
+
Add resources `Tax::CalculationLineItem`, `Tax::TransactionLineItem`, and `Treasury::FinancialAccountFeatures`. These resources have no methods on them, but do represent the return type of methods elsewhere.
|
6
|
+
|
7
|
+
## 8.6.0 - 2023-07-13
|
8
|
+
* [#1244](https://github.com/stripe/stripe-ruby/pull/1244) Update generated code
|
9
|
+
* Add support for new resource `Tax.Settings`
|
10
|
+
* Add support for `retrieve` and `update` methods on resource `Settings`
|
11
|
+
* [#1241](https://github.com/stripe/stripe-ruby/pull/1241) Update generated code
|
12
|
+
|
13
|
+
* [#1209](https://github.com/stripe/stripe-ruby/pull/1209) Update shoulda-context version
|
14
|
+
* [#1235](https://github.com/stripe/stripe-ruby/pull/1235) Allow "error" string as log level
|
15
|
+
* [#1238](https://github.com/stripe/stripe-ruby/pull/1238) Update log level error message to include `error`
|
16
|
+
* [#1231](https://github.com/stripe/stripe-ruby/pull/1231) fix: variable typo in README for instrumentation
|
17
|
+
* [#1234](https://github.com/stripe/stripe-ruby/pull/1234) Update generated code
|
18
|
+
|
19
|
+
* [#1230](https://github.com/stripe/stripe-ruby/pull/1230) Update generated code
|
20
|
+
* Release specs are identical.
|
21
|
+
* [#1226](https://github.com/stripe/stripe-ruby/pull/1226) Update generated code
|
22
|
+
|
23
|
+
* [#1223](https://github.com/stripe/stripe-ruby/pull/1223) Update generated code
|
24
|
+
|
25
|
+
* [#1225](https://github.com/stripe/stripe-ruby/pull/1225) Downgrade jaro_winkler
|
26
|
+
* [#1219](https://github.com/stripe/stripe-ruby/pull/1219) Update generated code
|
27
|
+
|
28
|
+
Documentation updates.
|
29
|
+
* [#1215](https://github.com/stripe/stripe-ruby/pull/1215) Update generated code
|
30
|
+
|
31
|
+
* [#1208](https://github.com/stripe/stripe-ruby/pull/1208) Update generated code
|
32
|
+
|
33
|
+
* [#1204](https://github.com/stripe/stripe-ruby/pull/1204) Update generated code
|
34
|
+
|
35
|
+
|
36
|
+
## 8.5.0 - 2023-03-30
|
37
|
+
* [#1203](https://github.com/stripe/stripe-ruby/pull/1203) Update generated code
|
38
|
+
* Remove support for `create` method on resource `Tax.Transaction`
|
39
|
+
* This is not a breaking change, as this method was deprecated before the Tax Transactions API was released in favor of the `create_from_calculation` method.
|
40
|
+
* [#1201](https://github.com/stripe/stripe-ruby/pull/1201) Update save deprecation message
|
41
|
+
|
42
|
+
## 8.4.0 - 2023-03-23
|
43
|
+
* [#1197](https://github.com/stripe/stripe-ruby/pull/1197) Update generated code (new)
|
44
|
+
* Add support for new resources `Tax.CalculationLineItem`, `Tax.Calculation`, `Tax.TransactionLineItem`, and `Tax.Transaction`
|
45
|
+
* Add support for `create` and `list_line_items` methods on resource `Calculation`
|
46
|
+
* Add support for `create_from_calculation`, `create_reversal`, `create`, `list_line_items`, and `retrieve` methods on resource `Transaction`
|
47
|
+
* [#1152](https://github.com/stripe/stripe-ruby/pull/1152) Symbolize hash keys inside `convert_to_stripe_object_with_params`
|
48
|
+
|
49
|
+
## 8.3.0 - 2023-02-16
|
50
|
+
* [#1175](https://github.com/stripe/stripe-ruby/pull/1175) API Updates
|
51
|
+
* Add support for `refund_payment` method on resource `Terminal.Reader`
|
52
|
+
|
53
|
+
## 8.2.0 - 2023-02-02
|
54
|
+
* [#1173](https://github.com/stripe/stripe-ruby/pull/1173) API Updates
|
55
|
+
* Add support for `resume` method on resource `Subscription`
|
56
|
+
* [#1171](https://github.com/stripe/stripe-ruby/pull/1171) Remove unused `partial` param from `initialize_from`
|
57
|
+
|
58
|
+
## 8.1.0 - 2023-01-12
|
59
|
+
* [#1162](https://github.com/stripe/stripe-ruby/pull/1162) Improve request events instrumentation
|
60
|
+
|
61
|
+
## 8.0.0 - 2022-11-16
|
62
|
+
* [#1144](https://github.com/stripe/stripe-ruby/pull/1144) Next major release changes
|
63
|
+
|
64
|
+
Breaking changes that arose during code generation of the library that we postponed for the next major version. For changes to the Stripe products, read more at https://stripe.com/docs/upgrades#2022-11-15.
|
65
|
+
|
66
|
+
"⚠️" symbol highlights breaking changes.
|
67
|
+
|
68
|
+
### Deprecated
|
69
|
+
- The `save` method is deprecated. Prefer the static `update` method that doesn't require retrieval of the resource to update it.
|
70
|
+
``` ruby
|
71
|
+
# before
|
72
|
+
refund = Stripe::Refund.retrieve("re_123")
|
73
|
+
refund.description = "Refund description"
|
74
|
+
refund.save
|
75
|
+
|
76
|
+
# after
|
77
|
+
Stripe::Refund.update("re_123", description: "Refund description")
|
78
|
+
```
|
79
|
+
|
80
|
+
### ⚠️ Removed
|
81
|
+
- Removed deprecated `Sku` resource.
|
82
|
+
- Removed deprecated `Orders` resource.
|
83
|
+
- Removed deprecated `delete` method on `Subscription` resource. Please use `cancel` method instead.
|
84
|
+
```ruby
|
85
|
+
# before
|
86
|
+
Stripe::Subscription::delete("sub_12345")
|
87
|
+
|
88
|
+
# after
|
89
|
+
Stripe::Subscription::cancel("sub_12345")
|
90
|
+
```
|
91
|
+
|
92
|
+
|
93
|
+
## 7.1.0 - 2022-08-19
|
94
|
+
* [#1116](https://github.com/stripe/stripe-ruby/pull/1116) API Updates
|
95
|
+
* Add support for new resource `CustomerCashBalanceTransaction`
|
96
|
+
* [#1118](https://github.com/stripe/stripe-ruby/pull/1118) Update AllowedChars in rubocop config
|
97
|
+
* [#1117](https://github.com/stripe/stripe-ruby/pull/1117) Refresh rubocop config.
|
98
|
+
* [#1115](https://github.com/stripe/stripe-ruby/pull/1115) Add a support section to the readme
|
99
|
+
|
100
|
+
## 7.0.0 - 2022-08-02
|
101
|
+
|
102
|
+
Breaking changes that arose during code generation of the library that we postponed for the next major version. For changes to the SDK, read more detailed description at https://github.com/stripe/stripe-ruby/wiki/Migration-guide-for-v7. For changes to the Stripe products, read more at https://stripe.com/docs/upgrades#2022-08-01.
|
103
|
+
|
104
|
+
"⚠️" symbol highlights breaking changes.
|
105
|
+
|
106
|
+
* [#1106](https://github.com/stripe/stripe-ruby/pull/1106) API Updates
|
107
|
+
* [#1092](https://github.com/stripe/stripe-ruby/pull/1092) API Updates
|
108
|
+
* [#1090](https://github.com/stripe/stripe-ruby/pull/1090) Use auto-generation for `Invoice` methods
|
109
|
+
* [#1103](https://github.com/stripe/stripe-ruby/pull/1103) Next major release changes
|
110
|
+
|
111
|
+
### ⚠️ Changed
|
112
|
+
* `retrieve_cash_balance` and `update_cash_balance` methods on `Customer` resource no longer requires the second argument to always be `nil`. The methods now now take in `customer_id`, `params`, and `opts` parameters.
|
113
|
+
* Update default bundle of CA certificates to April 26, 2022.
|
114
|
+
|
115
|
+
### Deprecated
|
116
|
+
* Deprecate `delete` method on `Subscription` resource. Please use `cancel` method instead.
|
117
|
+
|
118
|
+
### ⚠️ Removed
|
119
|
+
* Remove `details` method from `Issuing.Card` resource. The method was not supported.
|
120
|
+
* Remove `Issuing.CardDetails` resource. Read more at https://stripe.com/docs/issuing/cards/virtual.
|
121
|
+
* Remove `create` method from `ReportType` resource. The method was not supported.
|
122
|
+
* Remove `usage_record_summaries` method from `SubscriptionItem` resource. Please use `list_usage_record_summaries` method instead.
|
123
|
+
* Remove `AlipayAccount`, `BitcoinReceiver`, `BitcoinTransaction`, `Issuing::CardDetails`, `Recipient`, ` RecipientTransfer`, and `ThreeDSecure` resources. The resources were deprecated or no longer in use.
|
124
|
+
* Remove ability to list `Card` resource for a `Recipient`.
|
125
|
+
* Remove `cancel` method from `Transfer` resource. The method was deprecated.
|
126
|
+
|
127
|
+
## 6.5.0 - 2022-06-29
|
128
|
+
* [#1084](https://github.com/stripe/stripe-ruby/pull/1084) API Updates
|
129
|
+
* Add support for `deliver_card`, `fail_card`, `return_card`, and `ship_card` test helper methods on resource `Issuing.Card`
|
130
|
+
* [#1076](https://github.com/stripe/stripe-ruby/pull/1076) fix: Update logging to coerce ASCII-8BIT into UTF-8.
|
131
|
+
|
132
|
+
## 6.4.0 - 2022-06-17
|
133
|
+
* [#1073](https://github.com/stripe/stripe-ruby/pull/1073) API Updates
|
134
|
+
* Add support for `fund_cash_balance` test helper method on resource `Customer`
|
135
|
+
* [#1074](https://github.com/stripe/stripe-ruby/pull/1074) Support updating pre-release versions
|
136
|
+
* [#1072](https://github.com/stripe/stripe-ruby/pull/1072) Trigger workflows on beta branches
|
137
|
+
* [#1071](https://github.com/stripe/stripe-ruby/pull/1071) Use request_stripe_object for all requests
|
138
|
+
* [#1070](https://github.com/stripe/stripe-ruby/pull/1070) API Updates
|
139
|
+
|
140
|
+
Switch from using meta-programing to generating explicit methods for custom methods.
|
141
|
+
* [#1069](https://github.com/stripe/stripe-ruby/pull/1069) chore: Stop special implementation of Account.persons method.
|
142
|
+
|
143
|
+
## 6.3.0 - 2022-06-08
|
144
|
+
* [#1063](https://github.com/stripe/stripe-ruby/pull/1063) fix: Update cash balance methods to no longer require nested ID.
|
145
|
+
|
146
|
+
## 6.2.0 - 2022-05-23
|
147
|
+
* [#1060](https://github.com/stripe/stripe-ruby/pull/1060) API Updates
|
148
|
+
* Add support for new resource `Apps.Secret`
|
149
|
+
|
150
|
+
## 6.1.0 - 2022-05-19
|
151
|
+
* [#1057](https://github.com/stripe/stripe-ruby/pull/1057) API Updates
|
152
|
+
* Add support for new resources `Treasury.CreditReversal`, `Treasury.DebitReversal`, `Treasury.FinancialAccountFeatures`, `Treasury.FinancialAccount`, `Treasury.FlowDetails`, `Treasury.InboundTransfer`, `Treasury.OutboundPayment`, `Treasury.OutboundTransfer`, `Treasury.ReceivedCredit`, `Treasury.ReceivedDebit`, `Treasury.TransactionEntry`, and `Treasury.Transaction`
|
153
|
+
* Add support for `retrieve_payment_method` method on resource `Customer`
|
154
|
+
* Add support for `list_owners` and `list` methods on resource `FinancialConnections.Account`
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
## 6.0.0 - 2022-05-09
|
159
|
+
* [#1056](https://github.com/stripe/stripe-ruby/pull/1056) API Updates
|
160
|
+
Major version release. The [migration guide](https://github.com/stripe/stripe-ruby/wiki/Migration-Guide-for-v6) contains more information.
|
161
|
+
|
162
|
+
(⚠️ = breaking changes):
|
163
|
+
* ⚠️ Replace the legacy `Order` API with the new `Order` API.
|
164
|
+
* New methods: `cancel`, `list_line_items`, `reopen`, and `submit`
|
165
|
+
* Removed methods: `pay` and `return_order`
|
166
|
+
* Removed resources: `OrderItem` and `OrderReturn`
|
167
|
+
* ⚠️ Rename `FinancialConnections::Account.refresh` to `FinancialConnections::Account.refresh_account
|
168
|
+
|
169
|
+
## 5.55.0 - 2022-05-05
|
170
|
+
* [#1055](https://github.com/stripe/stripe-ruby/pull/1055) API Updates
|
171
|
+
* Add support for new resources `FinancialConnections.AccountOwner`, `FinancialConnections.AccountOwnership`, `FinancialConnections.Account`, and `FinancialConnections.Session`
|
172
|
+
|
173
|
+
|
174
|
+
## 5.54.0 - 2022-05-03
|
175
|
+
* [#1053](https://github.com/stripe/stripe-ruby/pull/1053) API Updates
|
176
|
+
* Add support for new resource `CashBalance`
|
177
|
+
|
178
|
+
## 5.53.0 - 2022-04-21
|
179
|
+
* [#1050](https://github.com/stripe/stripe-ruby/pull/1050) API Updates
|
180
|
+
* Add support for `expire` test helper method on resource `Refund`
|
181
|
+
|
182
|
+
## 5.52.0 - 2022-04-18
|
183
|
+
* [#1046](https://github.com/stripe/stripe-ruby/pull/1046) [#1047](https://github.com/stripe/stripe-ruby/pull/1047) API Updates
|
184
|
+
* Add support for new resources `FundingInstructions` and `Terminal.Configuration`
|
185
|
+
|
186
|
+
## 5.51.0 - 2022-04-15
|
187
|
+
* [#1046](https://github.com/stripe/stripe-ruby/pull/1046) This release was incomplete and was yanked from RubyGems immediately after it was published.
|
188
|
+
|
189
|
+
## 5.50.0 - 2022-04-13
|
190
|
+
* [#1045](https://github.com/stripe/stripe-ruby/pull/1045) API Updates
|
191
|
+
* Add support for `increment_authorization` method on resource `PaymentIntent`
|
192
|
+
|
193
|
+
## 5.49.0 - 2022-04-08
|
194
|
+
* [#1043](https://github.com/stripe/stripe-ruby/pull/1043) API Updates
|
195
|
+
* Add support for `apply_customer_balance` method on resource `PaymentIntent`
|
196
|
+
|
197
|
+
## 5.48.0 - 2022-03-30
|
198
|
+
* [#1041](https://github.com/stripe/stripe-ruby/pull/1041) API Updates
|
199
|
+
* Add support for `cancel_action`, `process_payment_intent`, `process_setup_intent`, and `set_reader_display` methods on resource `Terminal.Reader`
|
200
|
+
|
201
|
+
## 5.47.0 - 2022-03-29
|
202
|
+
* [#1040](https://github.com/stripe/stripe-ruby/pull/1040) API Updates
|
203
|
+
* Add support for Search API
|
204
|
+
* Add support for `search` method on resources `Charge`, `Customer`, `Invoice`, `PaymentIntent`, `Price`, `Product`, and `Subscription`
|
205
|
+
|
206
|
+
* [#1034](https://github.com/stripe/stripe-ruby/pull/1034) Add supporting classes for test helper generation
|
207
|
+
|
208
|
+
## 5.46.0 - 2022-03-23
|
209
|
+
* [#1039](https://github.com/stripe/stripe-ruby/pull/1039) API Updates
|
210
|
+
* Add support for `cancel` method on resource `Refund`
|
211
|
+
* [#992](https://github.com/stripe/stripe-ruby/pull/992) Add support for Search API
|
212
|
+
|
213
|
+
## 5.45.0 - 2022-03-01
|
214
|
+
* [#1035](https://github.com/stripe/stripe-ruby/pull/1035) API Updates
|
215
|
+
* Add support for new resource `TestHelpers.TestClock`
|
216
|
+
|
217
|
+
## 5.44.0 - 2022-02-16
|
218
|
+
* [#1032](https://github.com/stripe/stripe-ruby/pull/1032) API Updates
|
219
|
+
* Add support for `verify_microdeposits` method on resources `PaymentIntent` and `SetupIntent`
|
220
|
+
|
221
|
+
## 5.43.0 - 2022-01-20
|
222
|
+
* [#1031](https://github.com/stripe/stripe-ruby/pull/1031) API Updates
|
223
|
+
* Add support for new resource `PaymentLink`
|
224
|
+
|
225
|
+
## 5.42.0 - 2021-12-13
|
226
|
+
* [#1022](https://github.com/stripe/stripe-ruby/pull/1022) Add connection manager logging and include object IDs in logging.
|
227
|
+
|
228
|
+
## 5.41.0 - 2021-11-16
|
229
|
+
* [#1017](https://github.com/stripe/stripe-ruby/pull/1017) API Updates
|
230
|
+
* Add support for new resource `ShippingRate`
|
231
|
+
|
232
|
+
## 5.40.0 - 2021-11-11
|
233
|
+
* [#1015](https://github.com/stripe/stripe-ruby/pull/1015) API Updates
|
234
|
+
* Add support for `expire` method on resource `Checkout.Session`
|
235
|
+
* [#1013](https://github.com/stripe/stripe-ruby/pull/1013) Add tests for child resources.
|
236
|
+
* [#1012](https://github.com/stripe/stripe-ruby/pull/1012) Add tests for namespaced resources.
|
237
|
+
* [#1011](https://github.com/stripe/stripe-ruby/pull/1011) codegen: 3 more files
|
238
|
+
|
239
|
+
## 5.39.0 - 2021-10-11
|
240
|
+
* [#1010](https://github.com/stripe/stripe-ruby/pull/1010) API Updates
|
241
|
+
* Add support for `list_payment_methods` method on resource `Customer`
|
242
|
+
|
243
|
+
## 5.38.0 - 2021-08-10
|
244
|
+
* [#993](https://github.com/stripe/stripe-ruby/pull/993) Add `request_id` to RequestEndEvent
|
245
|
+
* [#991](https://github.com/stripe/stripe-ruby/pull/991) Codegen more files
|
246
|
+
* [#989](https://github.com/stripe/stripe-ruby/pull/989) Remove unused API error types from docs.
|
247
|
+
|
248
|
+
## 5.37.0 - 2021-07-14
|
249
|
+
* [#988](https://github.com/stripe/stripe-ruby/pull/988) API Updates
|
250
|
+
* Add support for `list_computed_upfront_line_items` method on resource `Quote`
|
251
|
+
|
252
|
+
## 5.36.0 - 2021-07-09
|
253
|
+
* [#987](https://github.com/stripe/stripe-ruby/pull/987) Add support for `Quote` API
|
254
|
+
|
255
|
+
## 5.35.0 - 2021-06-30
|
256
|
+
* [#985](https://github.com/stripe/stripe-ruby/pull/985) Update normalize_opts to use dup instead of clone.
|
257
|
+
* [#982](https://github.com/stripe/stripe-ruby/pull/982) Deprecate travis
|
258
|
+
* [#983](https://github.com/stripe/stripe-ruby/pull/983) Add support for making a request and receiving the response as a stream.
|
259
|
+
|
260
|
+
## 5.34.0 - 2021-06-04
|
261
|
+
* [#981](https://github.com/stripe/stripe-ruby/pull/981) API Updates
|
262
|
+
* Add support for `TaxCode` API.
|
263
|
+
|
264
|
+
## 5.33.0 - 2021-05-19
|
265
|
+
* [#979](https://github.com/stripe/stripe-ruby/pull/979) Add support for the Identify VerificationSession and VerificationReport APIs
|
266
|
+
|
267
|
+
## 5.32.1 - 2021-04-05
|
268
|
+
* Correct use of regexp `match` in gemspec for old versions of Ruby
|
269
|
+
|
270
|
+
## 5.32.0 - 2021-04-05
|
271
|
+
* [#973](https://github.com/stripe/stripe-ruby/pull/973) Reduce packed gem size
|
272
|
+
|
273
|
+
## 5.31.0 - 2021-04-02
|
274
|
+
* [#968](https://github.com/stripe/stripe-ruby/pull/968) Allow StripeClient to be configured per instance
|
275
|
+
* [#971](https://github.com/stripe/stripe-ruby/pull/971) On config change, only clear connection managers for changed config
|
276
|
+
* [#972](https://github.com/stripe/stripe-ruby/pull/972) Rename `Stripe.configuration` to `Stripe.config`
|
277
|
+
* [#970](https://github.com/stripe/stripe-ruby/pull/970) Reserve some critical field names when adding `StripeObject` accessors
|
278
|
+
* [#967](https://github.com/stripe/stripe-ruby/pull/967) CI: github actions
|
279
|
+
|
280
|
+
## 5.30.0 - 2021-02-22
|
281
|
+
* [#965](https://github.com/stripe/stripe-ruby/pull/965) Add support for the Billing Portal Configuration API
|
282
|
+
|
283
|
+
## 5.29.1 - 2021-02-09
|
284
|
+
* [#964](https://github.com/stripe/stripe-ruby/pull/964) Fix return value of `Customer#delete_discount`
|
285
|
+
|
286
|
+
## 5.29.0 - 2021-01-05
|
287
|
+
* [#952](https://github.com/stripe/stripe-ruby/pull/952) Allow client_id configuration on instance config
|
288
|
+
|
3
289
|
## 5.28.0 - 2020-10-14
|
4
290
|
* [#950](https://github.com/stripe/stripe-ruby/pull/950) Add configuration option for `write_timeout` for connections on Ruby 2.6+
|
5
291
|
|
data/Gemfile
CHANGED
@@ -5,13 +5,12 @@ source "https://rubygems.org"
|
|
5
5
|
gemspec
|
6
6
|
|
7
7
|
group :development do
|
8
|
-
gem "
|
8
|
+
gem "coveralls_reborn", "~> 0.25.0" if RUBY_VERSION >= "3.1"
|
9
9
|
gem "mocha", "~> 0.13.2"
|
10
10
|
gem "rack", ">= 2.0.6"
|
11
11
|
gem "rake"
|
12
12
|
|
13
|
-
|
14
|
-
gem "shoulda-context", "2.0.0.rc4"
|
13
|
+
gem "shoulda-context", "2.0.0"
|
15
14
|
|
16
15
|
gem "test-unit"
|
17
16
|
|
@@ -26,6 +25,9 @@ group :development do
|
|
26
25
|
# up-to-date, but it's not the end of the world if it's not.
|
27
26
|
gem "rubocop", "0.80"
|
28
27
|
|
28
|
+
# jaro_winkler 1.5.5 installation fails for jruby
|
29
|
+
gem "jaro_winkler", "1.5.4"
|
30
|
+
|
29
31
|
platforms :mri do
|
30
32
|
gem "byebug"
|
31
33
|
gem "pry"
|
data/Makefile
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
.PHONY: update-version codegen-format test ci-test
|
2
|
+
update-version:
|
3
|
+
@echo "$(VERSION)" > VERSION
|
4
|
+
@perl -pi -e 's|VERSION = "[.\-\w\d]+"|VERSION = "$(VERSION)"|' lib/stripe/version.rb
|
5
|
+
|
6
|
+
codegen-format:
|
7
|
+
bundle install --quiet
|
8
|
+
bundle exec rubocop -o /dev/null --auto-correct
|
9
|
+
|
10
|
+
ci-test:
|
11
|
+
bundle install && bundle exec rake test
|
12
|
+
|
13
|
+
test: ci-test
|
data/OPENAPI_VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
v457
|
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# Stripe Ruby Library
|
2
2
|
|
3
3
|
[![Gem Version](https://badge.fury.io/rb/stripe.svg)](https://badge.fury.io/rb/stripe)
|
4
|
-
[![Build Status](https://
|
4
|
+
[![Build Status](https://github.com/stripe/stripe-ruby/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/stripe/stripe-ruby/actions?query=branch%3Amaster)
|
5
5
|
[![Coverage Status](https://coveralls.io/repos/github/stripe/stripe-ruby/badge.svg?branch=master)](https://coveralls.io/github/stripe/stripe-ruby?branch=master)
|
6
6
|
|
7
7
|
The Stripe Ruby library provides convenient access to the Stripe API from
|
@@ -19,7 +19,10 @@ The library also provides other features. For example:
|
|
19
19
|
|
20
20
|
## Documentation
|
21
21
|
|
22
|
-
See the [Ruby API docs](https://stripe.com/docs/api
|
22
|
+
See the [Ruby API docs](https://stripe.com/docs/api?lang=ruby).
|
23
|
+
|
24
|
+
See [video demonstrations][youtube-playlist] covering how to use the library.
|
25
|
+
|
23
26
|
|
24
27
|
## Installation
|
25
28
|
|
@@ -250,6 +253,11 @@ a success or error. Receives `RequestEndEvent` with the following properties:
|
|
250
253
|
- `path`: Request path. (`String`)
|
251
254
|
- `user_data`: A hash on which users may have set arbitrary data in
|
252
255
|
`request_begin`. See above for more information. (`Hash`)
|
256
|
+
- `request_id`: HTTP request identifier. (`String`)
|
257
|
+
- `response_header`: The response headers. (`Hash`)
|
258
|
+
- `response_body` = The response body. (`String`)
|
259
|
+
- `request_header` = The request headers. (`Hash`)
|
260
|
+
- `request_body` = The request body. (`String`)
|
253
261
|
|
254
262
|
#### Example
|
255
263
|
|
@@ -257,9 +265,13 @@ For example:
|
|
257
265
|
|
258
266
|
```ruby
|
259
267
|
Stripe::Instrumentation.subscribe(:request_end) do |request_event|
|
268
|
+
# Filter out high-cardinality ids from `path`
|
269
|
+
path_parts = request_event.path.split("/").drop(2)
|
270
|
+
resource = path_parts.map { |part| part.match?(/\A[a-z_]+\z/) ? part : ":id" }.join("/")
|
271
|
+
|
260
272
|
tags = {
|
261
273
|
method: request_event.method,
|
262
|
-
resource:
|
274
|
+
resource: resource,
|
263
275
|
code: request_event.http_status,
|
264
276
|
retries: request_event.num_retries
|
265
277
|
}
|
@@ -290,6 +302,31 @@ You can disable this behavior if you prefer:
|
|
290
302
|
Stripe.enable_telemetry = false
|
291
303
|
```
|
292
304
|
|
305
|
+
### Beta SDKs
|
306
|
+
|
307
|
+
Stripe has features in the beta phase that can be accessed via the beta version of this package.
|
308
|
+
We would love for you to try these and share feedback with us before these features reach the stable phase.
|
309
|
+
To install a beta version use `gem install` with the exact version you'd like to use:
|
310
|
+
|
311
|
+
```sh
|
312
|
+
gem install stripe -v 7.1.0.pre.beta.2
|
313
|
+
```
|
314
|
+
|
315
|
+
> **Note**
|
316
|
+
> There can be breaking changes between beta versions. Therefore we recommend pinning the package version to a specific beta version in your Gemfile. This way you can install the same version each time without breaking changes unless you are intentionally looking for the latest beta version.
|
317
|
+
|
318
|
+
We highly recommend keeping an eye on when the beta feature you are interested in goes from beta to stable so that you can move from using a beta version of the SDK to the stable version.
|
319
|
+
|
320
|
+
If your beta feature requires a `Stripe-Version` header to be sent, use the `Stripe.api_version` field to set it:
|
321
|
+
|
322
|
+
```python
|
323
|
+
Stripe.api_version += "; feature_beta=v3"
|
324
|
+
```
|
325
|
+
|
326
|
+
## Support
|
327
|
+
|
328
|
+
New features and bug fixes are released on the latest major version of the Stripe Ruby library. If you are on an older major version, we recommend that you upgrade to the latest in order to use the new features and bug fixes including those for security vulnerabilities. Older major versions of the package will continue to be available for use, but will not be receiving any updates.
|
329
|
+
|
293
330
|
## Development
|
294
331
|
|
295
332
|
The test suite depends on [stripe-mock], so make sure to fetch and run it from a
|
@@ -337,9 +374,10 @@ Update the bundled [stripe-mock] by editing the version number found in
|
|
337
374
|
[api-keys]: https://dashboard.stripe.com/account/apikeys
|
338
375
|
[connect]: https://stripe.com/connect
|
339
376
|
[curl]: http://curl.haxx.se/docs/caextract.html
|
340
|
-
[idempotency-keys]: https://stripe.com/docs/api/ruby
|
377
|
+
[idempotency-keys]: https://stripe.com/docs/api/idempotent_requests?lang=ruby
|
341
378
|
[stripe-mock]: https://github.com/stripe/stripe-mock
|
342
|
-
[versioning]: https://stripe.com/docs/api/ruby
|
379
|
+
[versioning]: https://stripe.com/docs/api/versioning?lang=ruby
|
380
|
+
[youtube-playlist]: https://www.youtube.com/playlist?list=PLy1nL-pvL2M50RmP6ie-gdcSnfOuQCRYk
|
343
381
|
|
344
382
|
<!--
|
345
383
|
# vim: set tw=79:
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
8.7.0
|