stripe 5.28.0 → 8.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (243) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +286 -0
  3. data/Gemfile +5 -3
  4. data/Makefile +13 -0
  5. data/OPENAPI_VERSION +1 -0
  6. data/README.md +43 -5
  7. data/VERSION +1 -1
  8. data/lib/data/ca-certificates.crt +1241 -1937
  9. data/lib/stripe/api_operations/create.rb +6 -2
  10. data/lib/stripe/api_operations/delete.rb +12 -7
  11. data/lib/stripe/api_operations/list.rb +6 -9
  12. data/lib/stripe/api_operations/nested_resource.rb +62 -34
  13. data/lib/stripe/api_operations/request.rb +45 -2
  14. data/lib/stripe/api_operations/save.rb +13 -3
  15. data/lib/stripe/api_operations/search.rb +16 -0
  16. data/lib/stripe/api_resource.rb +11 -18
  17. data/lib/stripe/api_resource_test_helpers.rb +49 -0
  18. data/lib/stripe/api_version.rb +8 -0
  19. data/lib/stripe/connection_manager.rb +49 -11
  20. data/lib/stripe/error_object.rb +2 -3
  21. data/lib/stripe/instrumentation.rb +46 -6
  22. data/lib/stripe/oauth.rb +4 -3
  23. data/lib/stripe/object_types.rb +36 -10
  24. data/lib/stripe/resources/account.rb +39 -17
  25. data/lib/stripe/resources/account_link.rb +4 -0
  26. data/lib/stripe/resources/application_fee_refund.rb +7 -1
  27. data/lib/stripe/resources/apps/secret.rb +40 -0
  28. data/lib/stripe/resources/balance.rb +11 -0
  29. data/lib/stripe/resources/balance_transaction.rb +4 -0
  30. data/lib/stripe/resources/bank_account.rb +7 -0
  31. data/lib/stripe/resources/billing_portal/configuration.rb +15 -0
  32. data/lib/stripe/resources/billing_portal/session.rb +14 -0
  33. data/lib/stripe/resources/capability.rb +5 -1
  34. data/lib/stripe/resources/card.rb +6 -3
  35. data/lib/stripe/resources/cash_balance.rb +23 -0
  36. data/lib/stripe/resources/charge.rb +23 -3
  37. data/lib/stripe/resources/checkout/session.rb +49 -2
  38. data/lib/stripe/resources/country_spec.rb +6 -0
  39. data/lib/stripe/resources/coupon.rb +3 -0
  40. data/lib/stripe/resources/credit_note.rb +27 -9
  41. data/lib/stripe/resources/credit_note_line_item.rb +2 -0
  42. data/lib/stripe/resources/customer.rb +132 -4
  43. data/lib/stripe/resources/customer_balance_transaction.rb +9 -2
  44. data/lib/stripe/resources/customer_cash_balance_transaction.rb +14 -0
  45. data/lib/stripe/resources/discount.rb +5 -0
  46. data/lib/stripe/resources/dispute.rb +17 -3
  47. data/lib/stripe/resources/event.rb +29 -0
  48. data/lib/stripe/resources/exchange_rate.rb +11 -0
  49. data/lib/stripe/resources/file.rb +9 -1
  50. data/lib/stripe/resources/file_link.rb +3 -0
  51. data/lib/stripe/resources/financial_connections/account.rb +67 -0
  52. data/lib/stripe/resources/financial_connections/account_owner.rb +11 -0
  53. data/lib/stripe/resources/financial_connections/account_ownership.rb +11 -0
  54. data/lib/stripe/resources/financial_connections/session.rb +13 -0
  55. data/lib/stripe/resources/funding_instructions.rb +21 -0
  56. data/lib/stripe/resources/identity/verification_report.rb +23 -0
  57. data/lib/stripe/resources/identity/verification_session.rb +61 -0
  58. data/lib/stripe/resources/invoice.rb +105 -17
  59. data/lib/stripe/resources/invoice_item.rb +11 -0
  60. data/lib/stripe/resources/invoice_line_item.rb +1 -0
  61. data/lib/stripe/resources/issuing/authorization.rb +25 -5
  62. data/lib/stripe/resources/issuing/card.rb +78 -8
  63. data/lib/stripe/resources/issuing/cardholder.rb +3 -0
  64. data/lib/stripe/resources/issuing/dispute.rb +13 -3
  65. data/lib/stripe/resources/issuing/transaction.rb +5 -0
  66. data/lib/stripe/resources/line_item.rb +2 -0
  67. data/lib/stripe/resources/login_link.rb +2 -0
  68. data/lib/stripe/resources/mandate.rb +1 -0
  69. data/lib/stripe/resources/payment_intent.rb +103 -6
  70. data/lib/stripe/resources/payment_link.rb +35 -0
  71. data/lib/stripe/resources/payment_method.rb +25 -5
  72. data/lib/stripe/resources/payout.rb +28 -5
  73. data/lib/stripe/resources/person.rb +7 -0
  74. data/lib/stripe/resources/plan.rb +8 -0
  75. data/lib/stripe/resources/price.rb +15 -0
  76. data/lib/stripe/resources/product.rb +17 -0
  77. data/lib/stripe/resources/promotion_code.rb +2 -0
  78. data/lib/stripe/resources/quote.rb +128 -0
  79. data/lib/stripe/resources/radar/early_fraud_warning.rb +4 -0
  80. data/lib/stripe/resources/radar/value_list.rb +3 -0
  81. data/lib/stripe/resources/radar/value_list_item.rb +3 -0
  82. data/lib/stripe/resources/refund.rb +49 -0
  83. data/lib/stripe/resources/reporting/report_run.rb +8 -0
  84. data/lib/stripe/resources/reporting/report_type.rb +8 -1
  85. data/lib/stripe/resources/reversal.rb +16 -2
  86. data/lib/stripe/resources/review.rb +14 -3
  87. data/lib/stripe/resources/setup_attempt.rb +4 -0
  88. data/lib/stripe/resources/setup_intent.rb +60 -5
  89. data/lib/stripe/resources/shipping_rate.rb +14 -0
  90. data/lib/stripe/resources/sigma/scheduled_query_run.rb +4 -0
  91. data/lib/stripe/resources/source.rb +26 -6
  92. data/lib/stripe/resources/source_transaction.rb +5 -0
  93. data/lib/stripe/resources/subscription.rb +57 -3
  94. data/lib/stripe/resources/subscription_item.rb +2 -7
  95. data/lib/stripe/resources/subscription_schedule.rb +23 -5
  96. data/lib/stripe/resources/tax/calculation.rb +33 -0
  97. data/lib/stripe/resources/tax/calculation_line_item.rb +10 -0
  98. data/lib/stripe/resources/tax/settings.rb +15 -0
  99. data/lib/stripe/resources/tax/transaction.rb +49 -0
  100. data/lib/stripe/resources/tax/transaction_line_item.rb +10 -0
  101. data/lib/stripe/resources/tax_code.rb +11 -0
  102. data/lib/stripe/resources/tax_id.rb +5 -0
  103. data/lib/stripe/resources/tax_rate.rb +3 -0
  104. data/lib/stripe/resources/terminal/configuration.rb +16 -0
  105. data/lib/stripe/resources/terminal/connection_token.rb +3 -0
  106. data/lib/stripe/resources/terminal/location.rb +3 -0
  107. data/lib/stripe/resources/terminal/reader.rb +119 -0
  108. data/lib/stripe/resources/test_helpers/test_clock.rb +35 -0
  109. data/lib/stripe/resources/token.rb +20 -0
  110. data/lib/stripe/resources/topup.rb +15 -3
  111. data/lib/stripe/resources/transfer.rb +10 -11
  112. data/lib/stripe/resources/treasury/credit_reversal.rb +14 -0
  113. data/lib/stripe/resources/treasury/debit_reversal.rb +14 -0
  114. data/lib/stripe/resources/treasury/financial_account.rb +52 -0
  115. data/lib/stripe/resources/treasury/financial_account_features.rb +12 -0
  116. data/lib/stripe/resources/treasury/inbound_transfer.rb +94 -0
  117. data/lib/stripe/resources/treasury/outbound_payment.rb +96 -0
  118. data/lib/stripe/resources/treasury/outbound_transfer.rb +100 -0
  119. data/lib/stripe/resources/treasury/received_credit.rb +30 -0
  120. data/lib/stripe/resources/treasury/received_debit.rb +30 -0
  121. data/lib/stripe/resources/treasury/transaction.rb +13 -0
  122. data/lib/stripe/resources/treasury/transaction_entry.rb +17 -0
  123. data/lib/stripe/resources/usage_record.rb +5 -0
  124. data/lib/stripe/resources/usage_record_summary.rb +1 -0
  125. data/lib/stripe/resources/webhook_endpoint.rb +7 -0
  126. data/lib/stripe/resources.rb +34 -10
  127. data/lib/stripe/search_result_object.rb +86 -0
  128. data/lib/stripe/stripe_client.rb +267 -121
  129. data/lib/stripe/stripe_configuration.rb +29 -10
  130. data/lib/stripe/stripe_object.rb +25 -2
  131. data/lib/stripe/stripe_response.rb +80 -52
  132. data/lib/stripe/util.rb +100 -9
  133. data/lib/stripe/version.rb +1 -1
  134. data/lib/stripe.rb +27 -23
  135. data/stripe.gemspec +12 -5
  136. metadata +46 -204
  137. data/.editorconfig +0 -10
  138. data/.gitattributes +0 -4
  139. data/.github/ISSUE_TEMPLATE.md +0 -5
  140. data/.gitignore +0 -8
  141. data/.rubocop.yml +0 -80
  142. data/.rubocop_todo.yml +0 -33
  143. data/.travis.yml +0 -38
  144. data/.vscode/extensions.json +0 -7
  145. data/.vscode/settings.json +0 -8
  146. data/lib/stripe/resources/bitcoin_receiver.rb +0 -24
  147. data/lib/stripe/resources/bitcoin_transaction.rb +0 -15
  148. data/lib/stripe/resources/issuing/card_details.rb +0 -9
  149. data/lib/stripe/resources/order.rb +0 -33
  150. data/lib/stripe/resources/order_return.rb +0 -10
  151. data/lib/stripe/resources/recipient.rb +0 -14
  152. data/lib/stripe/resources/sku.rb +0 -13
  153. data/lib/stripe/resources/three_d_secure.rb +0 -14
  154. data/test/openapi/README.md +0 -9
  155. data/test/stripe/account_link_test.rb +0 -18
  156. data/test/stripe/account_test.rb +0 -412
  157. data/test/stripe/alipay_account_test.rb +0 -37
  158. data/test/stripe/api_operations_test.rb +0 -80
  159. data/test/stripe/api_resource_test.rb +0 -646
  160. data/test/stripe/apple_pay_domain_test.rb +0 -46
  161. data/test/stripe/application_fee_refund_test.rb +0 -37
  162. data/test/stripe/application_fee_test.rb +0 -58
  163. data/test/stripe/balance_test.rb +0 -13
  164. data/test/stripe/balance_transaction_test.rb +0 -20
  165. data/test/stripe/bank_account_test.rb +0 -36
  166. data/test/stripe/billing_portal/session_test.rb +0 -18
  167. data/test/stripe/capability_test.rb +0 -45
  168. data/test/stripe/charge_test.rb +0 -64
  169. data/test/stripe/checkout/session_test.rb +0 -53
  170. data/test/stripe/connection_manager_test.rb +0 -167
  171. data/test/stripe/country_spec_test.rb +0 -20
  172. data/test/stripe/coupon_test.rb +0 -61
  173. data/test/stripe/credit_note_test.rb +0 -90
  174. data/test/stripe/customer_balance_transaction_test.rb +0 -37
  175. data/test/stripe/customer_card_test.rb +0 -48
  176. data/test/stripe/customer_test.rb +0 -226
  177. data/test/stripe/dispute_test.rb +0 -51
  178. data/test/stripe/ephemeral_key_test.rb +0 -93
  179. data/test/stripe/errors_test.rb +0 -53
  180. data/test/stripe/exchange_rate_test.rb +0 -20
  181. data/test/stripe/file_link_test.rb +0 -41
  182. data/test/stripe/file_test.rb +0 -87
  183. data/test/stripe/instrumentation_test.rb +0 -74
  184. data/test/stripe/invoice_item_test.rb +0 -66
  185. data/test/stripe/invoice_line_item_test.rb +0 -8
  186. data/test/stripe/invoice_test.rb +0 -229
  187. data/test/stripe/issuing/authorization_test.rb +0 -72
  188. data/test/stripe/issuing/card_test.rb +0 -74
  189. data/test/stripe/issuing/cardholder_test.rb +0 -53
  190. data/test/stripe/issuing/dispute_test.rb +0 -54
  191. data/test/stripe/issuing/transaction_test.rb +0 -48
  192. data/test/stripe/list_object_test.rb +0 -202
  193. data/test/stripe/login_link_test.rb +0 -37
  194. data/test/stripe/mandate_test.rb +0 -14
  195. data/test/stripe/multipart_encoder_test.rb +0 -130
  196. data/test/stripe/oauth_test.rb +0 -104
  197. data/test/stripe/order_return_test.rb +0 -21
  198. data/test/stripe/order_test.rb +0 -82
  199. data/test/stripe/payment_intent_test.rb +0 -107
  200. data/test/stripe/payment_method_test.rb +0 -84
  201. data/test/stripe/payout_test.rb +0 -72
  202. data/test/stripe/person_test.rb +0 -46
  203. data/test/stripe/plan_test.rb +0 -98
  204. data/test/stripe/price_test.rb +0 -48
  205. data/test/stripe/product_test.rb +0 -58
  206. data/test/stripe/promotion_code_test.rb +0 -42
  207. data/test/stripe/radar/early_fraud_warning_test.rb +0 -22
  208. data/test/stripe/radar/value_list_item_test.rb +0 -48
  209. data/test/stripe/radar/value_list_test.rb +0 -61
  210. data/test/stripe/recipient_test.rb +0 -62
  211. data/test/stripe/refund_test.rb +0 -39
  212. data/test/stripe/reporting/report_run_test.rb +0 -33
  213. data/test/stripe/reporting/report_type_test.rb +0 -22
  214. data/test/stripe/reversal_test.rb +0 -43
  215. data/test/stripe/review_test.rb +0 -27
  216. data/test/stripe/setup_attempt_test.rb +0 -16
  217. data/test/stripe/setup_intent_test.rb +0 -84
  218. data/test/stripe/sigma/scheduled_query_run_test.rb +0 -22
  219. data/test/stripe/sku_test.rb +0 -60
  220. data/test/stripe/source_test.rb +0 -119
  221. data/test/stripe/stripe_client_test.rb +0 -1291
  222. data/test/stripe/stripe_configuration_test.rb +0 -131
  223. data/test/stripe/stripe_object_test.rb +0 -500
  224. data/test/stripe/stripe_response_test.rb +0 -95
  225. data/test/stripe/subscription_item_test.rb +0 -84
  226. data/test/stripe/subscription_schedule_test.rb +0 -82
  227. data/test/stripe/subscription_test.rb +0 -80
  228. data/test/stripe/tax_id_test.rb +0 -31
  229. data/test/stripe/tax_rate_test.rb +0 -43
  230. data/test/stripe/terminal/connection_token_test.rb +0 -16
  231. data/test/stripe/terminal/location_test.rb +0 -68
  232. data/test/stripe/terminal/reader_test.rb +0 -62
  233. data/test/stripe/three_d_secure_test.rb +0 -23
  234. data/test/stripe/topup_test.rb +0 -62
  235. data/test/stripe/transfer_test.rb +0 -88
  236. data/test/stripe/usage_record_summary_test.rb +0 -29
  237. data/test/stripe/util_test.rb +0 -402
  238. data/test/stripe/webhook_endpoint_test.rb +0 -59
  239. data/test/stripe/webhook_test.rb +0 -135
  240. data/test/stripe_mock.rb +0 -78
  241. data/test/stripe_test.rb +0 -132
  242. data/test/test_data.rb +0 -61
  243. data/test/test_helper.rb +0 -77
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stripe
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.28.0
4
+ version: 8.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stripe
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-14 00:00:00.000000000 Z
11
+ date: 2023-08-11 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Stripe is the easiest way to accept payments online. See https://stripe.com
14
14
  for details.
@@ -18,21 +18,14 @@ executables:
18
18
  extensions: []
19
19
  extra_rdoc_files: []
20
20
  files:
21
- - ".editorconfig"
22
- - ".gitattributes"
23
- - ".github/ISSUE_TEMPLATE.md"
24
- - ".gitignore"
25
- - ".rubocop.yml"
26
- - ".rubocop_todo.yml"
27
- - ".travis.yml"
28
- - ".vscode/extensions.json"
29
- - ".vscode/settings.json"
30
21
  - CHANGELOG.md
31
22
  - CODE_OF_CONDUCT.md
32
23
  - CONTRIBUTORS
33
24
  - Gemfile
34
25
  - History.txt
35
26
  - LICENSE
27
+ - Makefile
28
+ - OPENAPI_VERSION
36
29
  - README.md
37
30
  - Rakefile
38
31
  - VERSION
@@ -45,7 +38,10 @@ files:
45
38
  - lib/stripe/api_operations/nested_resource.rb
46
39
  - lib/stripe/api_operations/request.rb
47
40
  - lib/stripe/api_operations/save.rb
41
+ - lib/stripe/api_operations/search.rb
48
42
  - lib/stripe/api_resource.rb
43
+ - lib/stripe/api_resource_test_helpers.rb
44
+ - lib/stripe/api_version.rb
49
45
  - lib/stripe/connection_manager.rb
50
46
  - lib/stripe/error_object.rb
51
47
  - lib/stripe/errors.rb
@@ -61,14 +57,15 @@ files:
61
57
  - lib/stripe/resources/apple_pay_domain.rb
62
58
  - lib/stripe/resources/application_fee.rb
63
59
  - lib/stripe/resources/application_fee_refund.rb
60
+ - lib/stripe/resources/apps/secret.rb
64
61
  - lib/stripe/resources/balance.rb
65
62
  - lib/stripe/resources/balance_transaction.rb
66
63
  - lib/stripe/resources/bank_account.rb
64
+ - lib/stripe/resources/billing_portal/configuration.rb
67
65
  - lib/stripe/resources/billing_portal/session.rb
68
- - lib/stripe/resources/bitcoin_receiver.rb
69
- - lib/stripe/resources/bitcoin_transaction.rb
70
66
  - lib/stripe/resources/capability.rb
71
67
  - lib/stripe/resources/card.rb
68
+ - lib/stripe/resources/cash_balance.rb
72
69
  - lib/stripe/resources/charge.rb
73
70
  - lib/stripe/resources/checkout/session.rb
74
71
  - lib/stripe/resources/country_spec.rb
@@ -77,6 +74,7 @@ files:
77
74
  - lib/stripe/resources/credit_note_line_item.rb
78
75
  - lib/stripe/resources/customer.rb
79
76
  - lib/stripe/resources/customer_balance_transaction.rb
77
+ - lib/stripe/resources/customer_cash_balance_transaction.rb
80
78
  - lib/stripe/resources/discount.rb
81
79
  - lib/stripe/resources/dispute.rb
82
80
  - lib/stripe/resources/ephemeral_key.rb
@@ -84,21 +82,26 @@ files:
84
82
  - lib/stripe/resources/exchange_rate.rb
85
83
  - lib/stripe/resources/file.rb
86
84
  - lib/stripe/resources/file_link.rb
85
+ - lib/stripe/resources/financial_connections/account.rb
86
+ - lib/stripe/resources/financial_connections/account_owner.rb
87
+ - lib/stripe/resources/financial_connections/account_ownership.rb
88
+ - lib/stripe/resources/financial_connections/session.rb
89
+ - lib/stripe/resources/funding_instructions.rb
90
+ - lib/stripe/resources/identity/verification_report.rb
91
+ - lib/stripe/resources/identity/verification_session.rb
87
92
  - lib/stripe/resources/invoice.rb
88
93
  - lib/stripe/resources/invoice_item.rb
89
94
  - lib/stripe/resources/invoice_line_item.rb
90
95
  - lib/stripe/resources/issuing/authorization.rb
91
96
  - lib/stripe/resources/issuing/card.rb
92
- - lib/stripe/resources/issuing/card_details.rb
93
97
  - lib/stripe/resources/issuing/cardholder.rb
94
98
  - lib/stripe/resources/issuing/dispute.rb
95
99
  - lib/stripe/resources/issuing/transaction.rb
96
100
  - lib/stripe/resources/line_item.rb
97
101
  - lib/stripe/resources/login_link.rb
98
102
  - lib/stripe/resources/mandate.rb
99
- - lib/stripe/resources/order.rb
100
- - lib/stripe/resources/order_return.rb
101
103
  - lib/stripe/resources/payment_intent.rb
104
+ - lib/stripe/resources/payment_link.rb
102
105
  - lib/stripe/resources/payment_method.rb
103
106
  - lib/stripe/resources/payout.rb
104
107
  - lib/stripe/resources/person.rb
@@ -106,10 +109,10 @@ files:
106
109
  - lib/stripe/resources/price.rb
107
110
  - lib/stripe/resources/product.rb
108
111
  - lib/stripe/resources/promotion_code.rb
112
+ - lib/stripe/resources/quote.rb
109
113
  - lib/stripe/resources/radar/early_fraud_warning.rb
110
114
  - lib/stripe/resources/radar/value_list.rb
111
115
  - lib/stripe/resources/radar/value_list_item.rb
112
- - lib/stripe/resources/recipient.rb
113
116
  - lib/stripe/resources/recipient_transfer.rb
114
117
  - lib/stripe/resources/refund.rb
115
118
  - lib/stripe/resources/reporting/report_run.rb
@@ -118,25 +121,44 @@ files:
118
121
  - lib/stripe/resources/review.rb
119
122
  - lib/stripe/resources/setup_attempt.rb
120
123
  - lib/stripe/resources/setup_intent.rb
124
+ - lib/stripe/resources/shipping_rate.rb
121
125
  - lib/stripe/resources/sigma/scheduled_query_run.rb
122
- - lib/stripe/resources/sku.rb
123
126
  - lib/stripe/resources/source.rb
124
127
  - lib/stripe/resources/source_transaction.rb
125
128
  - lib/stripe/resources/subscription.rb
126
129
  - lib/stripe/resources/subscription_item.rb
127
130
  - lib/stripe/resources/subscription_schedule.rb
131
+ - lib/stripe/resources/tax/calculation.rb
132
+ - lib/stripe/resources/tax/calculation_line_item.rb
133
+ - lib/stripe/resources/tax/settings.rb
134
+ - lib/stripe/resources/tax/transaction.rb
135
+ - lib/stripe/resources/tax/transaction_line_item.rb
136
+ - lib/stripe/resources/tax_code.rb
128
137
  - lib/stripe/resources/tax_id.rb
129
138
  - lib/stripe/resources/tax_rate.rb
139
+ - lib/stripe/resources/terminal/configuration.rb
130
140
  - lib/stripe/resources/terminal/connection_token.rb
131
141
  - lib/stripe/resources/terminal/location.rb
132
142
  - lib/stripe/resources/terminal/reader.rb
133
- - lib/stripe/resources/three_d_secure.rb
143
+ - lib/stripe/resources/test_helpers/test_clock.rb
134
144
  - lib/stripe/resources/token.rb
135
145
  - lib/stripe/resources/topup.rb
136
146
  - lib/stripe/resources/transfer.rb
147
+ - lib/stripe/resources/treasury/credit_reversal.rb
148
+ - lib/stripe/resources/treasury/debit_reversal.rb
149
+ - lib/stripe/resources/treasury/financial_account.rb
150
+ - lib/stripe/resources/treasury/financial_account_features.rb
151
+ - lib/stripe/resources/treasury/inbound_transfer.rb
152
+ - lib/stripe/resources/treasury/outbound_payment.rb
153
+ - lib/stripe/resources/treasury/outbound_transfer.rb
154
+ - lib/stripe/resources/treasury/received_credit.rb
155
+ - lib/stripe/resources/treasury/received_debit.rb
156
+ - lib/stripe/resources/treasury/transaction.rb
157
+ - lib/stripe/resources/treasury/transaction_entry.rb
137
158
  - lib/stripe/resources/usage_record.rb
138
159
  - lib/stripe/resources/usage_record_summary.rb
139
160
  - lib/stripe/resources/webhook_endpoint.rb
161
+ - lib/stripe/search_result_object.rb
140
162
  - lib/stripe/singleton_api_resource.rb
141
163
  - lib/stripe/stripe_client.rb
142
164
  - lib/stripe/stripe_configuration.rb
@@ -146,105 +168,15 @@ files:
146
168
  - lib/stripe/version.rb
147
169
  - lib/stripe/webhook.rb
148
170
  - stripe.gemspec
149
- - test/openapi/README.md
150
- - test/stripe/account_link_test.rb
151
- - test/stripe/account_test.rb
152
- - test/stripe/alipay_account_test.rb
153
- - test/stripe/api_operations_test.rb
154
- - test/stripe/api_resource_test.rb
155
- - test/stripe/apple_pay_domain_test.rb
156
- - test/stripe/application_fee_refund_test.rb
157
- - test/stripe/application_fee_test.rb
158
- - test/stripe/balance_test.rb
159
- - test/stripe/balance_transaction_test.rb
160
- - test/stripe/bank_account_test.rb
161
- - test/stripe/billing_portal/session_test.rb
162
- - test/stripe/capability_test.rb
163
- - test/stripe/charge_test.rb
164
- - test/stripe/checkout/session_test.rb
165
- - test/stripe/connection_manager_test.rb
166
- - test/stripe/country_spec_test.rb
167
- - test/stripe/coupon_test.rb
168
- - test/stripe/credit_note_test.rb
169
- - test/stripe/customer_balance_transaction_test.rb
170
- - test/stripe/customer_card_test.rb
171
- - test/stripe/customer_test.rb
172
- - test/stripe/dispute_test.rb
173
- - test/stripe/ephemeral_key_test.rb
174
- - test/stripe/errors_test.rb
175
- - test/stripe/exchange_rate_test.rb
176
- - test/stripe/file_link_test.rb
177
- - test/stripe/file_test.rb
178
- - test/stripe/instrumentation_test.rb
179
- - test/stripe/invoice_item_test.rb
180
- - test/stripe/invoice_line_item_test.rb
181
- - test/stripe/invoice_test.rb
182
- - test/stripe/issuing/authorization_test.rb
183
- - test/stripe/issuing/card_test.rb
184
- - test/stripe/issuing/cardholder_test.rb
185
- - test/stripe/issuing/dispute_test.rb
186
- - test/stripe/issuing/transaction_test.rb
187
- - test/stripe/list_object_test.rb
188
- - test/stripe/login_link_test.rb
189
- - test/stripe/mandate_test.rb
190
- - test/stripe/multipart_encoder_test.rb
191
- - test/stripe/oauth_test.rb
192
- - test/stripe/order_return_test.rb
193
- - test/stripe/order_test.rb
194
- - test/stripe/payment_intent_test.rb
195
- - test/stripe/payment_method_test.rb
196
- - test/stripe/payout_test.rb
197
- - test/stripe/person_test.rb
198
- - test/stripe/plan_test.rb
199
- - test/stripe/price_test.rb
200
- - test/stripe/product_test.rb
201
- - test/stripe/promotion_code_test.rb
202
- - test/stripe/radar/early_fraud_warning_test.rb
203
- - test/stripe/radar/value_list_item_test.rb
204
- - test/stripe/radar/value_list_test.rb
205
- - test/stripe/recipient_test.rb
206
- - test/stripe/refund_test.rb
207
- - test/stripe/reporting/report_run_test.rb
208
- - test/stripe/reporting/report_type_test.rb
209
- - test/stripe/reversal_test.rb
210
- - test/stripe/review_test.rb
211
- - test/stripe/setup_attempt_test.rb
212
- - test/stripe/setup_intent_test.rb
213
- - test/stripe/sigma/scheduled_query_run_test.rb
214
- - test/stripe/sku_test.rb
215
- - test/stripe/source_test.rb
216
- - test/stripe/stripe_client_test.rb
217
- - test/stripe/stripe_configuration_test.rb
218
- - test/stripe/stripe_object_test.rb
219
- - test/stripe/stripe_response_test.rb
220
- - test/stripe/subscription_item_test.rb
221
- - test/stripe/subscription_schedule_test.rb
222
- - test/stripe/subscription_test.rb
223
- - test/stripe/tax_id_test.rb
224
- - test/stripe/tax_rate_test.rb
225
- - test/stripe/terminal/connection_token_test.rb
226
- - test/stripe/terminal/location_test.rb
227
- - test/stripe/terminal/reader_test.rb
228
- - test/stripe/three_d_secure_test.rb
229
- - test/stripe/topup_test.rb
230
- - test/stripe/transfer_test.rb
231
- - test/stripe/usage_record_summary_test.rb
232
- - test/stripe/util_test.rb
233
- - test/stripe/webhook_endpoint_test.rb
234
- - test/stripe/webhook_test.rb
235
- - test/stripe_mock.rb
236
- - test/stripe_test.rb
237
- - test/test_data.rb
238
- - test/test_helper.rb
239
- homepage: https://stripe.com/docs/api/ruby
171
+ homepage: https://stripe.com/docs/api?lang=ruby
240
172
  licenses:
241
173
  - MIT
242
174
  metadata:
243
175
  bug_tracker_uri: https://github.com/stripe/stripe-ruby/issues
244
176
  changelog_uri: https://github.com/stripe/stripe-ruby/blob/master/CHANGELOG.md
245
- documentation_uri: https://stripe.com/docs/api/ruby
177
+ documentation_uri: https://stripe.com/docs/api?lang=ruby
246
178
  github_repo: ssh://github.com/stripe/stripe-ruby
247
- homepage_uri: https://stripe.com/docs/api/ruby
179
+ homepage_uri: https://stripe.com/docs/api?lang=ruby
248
180
  source_code_uri: https://github.com/stripe/stripe-ruby
249
181
  post_install_message:
250
182
  rdoc_options: []
@@ -261,98 +193,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
261
193
  - !ruby/object:Gem::Version
262
194
  version: '0'
263
195
  requirements: []
264
- rubygems_version: 3.1.2
196
+ rubygems_version: 3.3.26
265
197
  signing_key:
266
198
  specification_version: 4
267
199
  summary: Ruby bindings for the Stripe API
268
- test_files:
269
- - test/openapi/README.md
270
- - test/stripe/account_link_test.rb
271
- - test/stripe/account_test.rb
272
- - test/stripe/alipay_account_test.rb
273
- - test/stripe/api_operations_test.rb
274
- - test/stripe/api_resource_test.rb
275
- - test/stripe/apple_pay_domain_test.rb
276
- - test/stripe/application_fee_refund_test.rb
277
- - test/stripe/application_fee_test.rb
278
- - test/stripe/balance_test.rb
279
- - test/stripe/balance_transaction_test.rb
280
- - test/stripe/bank_account_test.rb
281
- - test/stripe/billing_portal/session_test.rb
282
- - test/stripe/capability_test.rb
283
- - test/stripe/charge_test.rb
284
- - test/stripe/checkout/session_test.rb
285
- - test/stripe/connection_manager_test.rb
286
- - test/stripe/country_spec_test.rb
287
- - test/stripe/coupon_test.rb
288
- - test/stripe/credit_note_test.rb
289
- - test/stripe/customer_balance_transaction_test.rb
290
- - test/stripe/customer_card_test.rb
291
- - test/stripe/customer_test.rb
292
- - test/stripe/dispute_test.rb
293
- - test/stripe/ephemeral_key_test.rb
294
- - test/stripe/errors_test.rb
295
- - test/stripe/exchange_rate_test.rb
296
- - test/stripe/file_link_test.rb
297
- - test/stripe/file_test.rb
298
- - test/stripe/instrumentation_test.rb
299
- - test/stripe/invoice_item_test.rb
300
- - test/stripe/invoice_line_item_test.rb
301
- - test/stripe/invoice_test.rb
302
- - test/stripe/issuing/authorization_test.rb
303
- - test/stripe/issuing/card_test.rb
304
- - test/stripe/issuing/cardholder_test.rb
305
- - test/stripe/issuing/dispute_test.rb
306
- - test/stripe/issuing/transaction_test.rb
307
- - test/stripe/list_object_test.rb
308
- - test/stripe/login_link_test.rb
309
- - test/stripe/mandate_test.rb
310
- - test/stripe/multipart_encoder_test.rb
311
- - test/stripe/oauth_test.rb
312
- - test/stripe/order_return_test.rb
313
- - test/stripe/order_test.rb
314
- - test/stripe/payment_intent_test.rb
315
- - test/stripe/payment_method_test.rb
316
- - test/stripe/payout_test.rb
317
- - test/stripe/person_test.rb
318
- - test/stripe/plan_test.rb
319
- - test/stripe/price_test.rb
320
- - test/stripe/product_test.rb
321
- - test/stripe/promotion_code_test.rb
322
- - test/stripe/radar/early_fraud_warning_test.rb
323
- - test/stripe/radar/value_list_item_test.rb
324
- - test/stripe/radar/value_list_test.rb
325
- - test/stripe/recipient_test.rb
326
- - test/stripe/refund_test.rb
327
- - test/stripe/reporting/report_run_test.rb
328
- - test/stripe/reporting/report_type_test.rb
329
- - test/stripe/reversal_test.rb
330
- - test/stripe/review_test.rb
331
- - test/stripe/setup_attempt_test.rb
332
- - test/stripe/setup_intent_test.rb
333
- - test/stripe/sigma/scheduled_query_run_test.rb
334
- - test/stripe/sku_test.rb
335
- - test/stripe/source_test.rb
336
- - test/stripe/stripe_client_test.rb
337
- - test/stripe/stripe_configuration_test.rb
338
- - test/stripe/stripe_object_test.rb
339
- - test/stripe/stripe_response_test.rb
340
- - test/stripe/subscription_item_test.rb
341
- - test/stripe/subscription_schedule_test.rb
342
- - test/stripe/subscription_test.rb
343
- - test/stripe/tax_id_test.rb
344
- - test/stripe/tax_rate_test.rb
345
- - test/stripe/terminal/connection_token_test.rb
346
- - test/stripe/terminal/location_test.rb
347
- - test/stripe/terminal/reader_test.rb
348
- - test/stripe/three_d_secure_test.rb
349
- - test/stripe/topup_test.rb
350
- - test/stripe/transfer_test.rb
351
- - test/stripe/usage_record_summary_test.rb
352
- - test/stripe/util_test.rb
353
- - test/stripe/webhook_endpoint_test.rb
354
- - test/stripe/webhook_test.rb
355
- - test/stripe_mock.rb
356
- - test/stripe_test.rb
357
- - test/test_data.rb
358
- - test/test_helper.rb
200
+ test_files: []
data/.editorconfig DELETED
@@ -1,10 +0,0 @@
1
- # see http://editorconfig.org/
2
-
3
- root = true
4
-
5
- [*]
6
- indent_style = space
7
- indent_size = 2
8
- end_of_line = lf
9
- charset = utf-8
10
- insert_final_newline = true
data/.gitattributes DELETED
@@ -1,4 +0,0 @@
1
- # may be useful in hiding large schema changes in pull request diffs (but not
2
- # using it for now)
3
- spec/*.json binary
4
- spec/*.yaml binary
@@ -1,5 +0,0 @@
1
- Please only file issues here that you believe represent actual bugs or feature requests for the Stripe Ruby library.
2
-
3
- If you're having general trouble with your Stripe integration, please reach out to support using the form at https://support.stripe.com/ (preferred) or via email to support@stripe.com.
4
-
5
- If you are reporting a bug, please include your Ruby version and the version of the Stripe Ruby library you're using, as well as any other details that may be helpful in reproducing the problem.
data/.gitignore DELETED
@@ -1,8 +0,0 @@
1
- /stripe-*.gem
2
- /Gemfile.lock
3
- .rvmrc
4
- Gemfile.lock
5
- tags
6
- /.bundle/
7
- coverage/
8
- .idea/
data/.rubocop.yml DELETED
@@ -1,80 +0,0 @@
1
- inherit_from: .rubocop_todo.yml
2
-
3
- AllCops:
4
- DisplayCopNames: true
5
- TargetRubyVersion: 2.3
6
-
7
- Exclude:
8
- # brandur: Exclude ephmeral script-like files that I use to try and
9
- # reproduce problems with the library. If you know of a better way of doing
10
- # this (e.g. exclude files not tracked by Git), feel free to change it.
11
- - "example_*"
12
-
13
- Layout/CaseIndentation:
14
- EnforcedStyle: end
15
-
16
- Layout/FirstArrayElementIndentation:
17
- EnforcedStyle: consistent
18
-
19
- Layout/FirstHashElementIndentation:
20
- EnforcedStyle: consistent
21
-
22
- # This can be re-enabled once we're 2.3+ only and can use the squiggly heredoc
23
- # operator. Prior to that, Rubocop recommended bringing in a library like
24
- # ActiveSupport to get heredoc indentation, which is just terrible.
25
- Layout/HeredocIndentation:
26
- Enabled: false
27
-
28
- Layout/LineLength:
29
- Exclude:
30
- - "lib/stripe/resources/**/*.rb"
31
- - "test/**/*.rb"
32
-
33
- Metrics/BlockLength:
34
- Max: 40
35
- Exclude:
36
- # `context` in tests are blocks and get quite large, so exclude the test
37
- # directory from having to adhere to this rule.
38
- - "test/**/*.rb"
39
-
40
- Metrics/ClassLength:
41
- Exclude:
42
- # Test classes get quite large, so exclude the test directory from having
43
- # to adhere to this rule.
44
- - "test/**/*.rb"
45
-
46
- Metrics/MethodLength:
47
- # There's ~2 long methods in `StripeClient` and one in `NestedResource`. If
48
- # we want to truncate those a little, we could move this to be closer to ~30
49
- # (but the default of 10 is probably too short).
50
- Max: 55
51
-
52
- Metrics/ModuleLength:
53
- Enabled: false
54
-
55
- Style/AccessModifierDeclarations:
56
- EnforcedStyle: inline
57
-
58
- Style/FrozenStringLiteralComment:
59
- EnforcedStyle: always
60
-
61
- Style/HashEachMethods:
62
- Enabled: true
63
-
64
- Style/HashTransformKeys:
65
- Enabled: true
66
-
67
- Style/HashTransformValues:
68
- Enabled: true
69
-
70
- Style/NumericPredicate:
71
- Enabled: false
72
-
73
- Style/StringLiterals:
74
- EnforcedStyle: double_quotes
75
-
76
- Style/TrailingCommaInArrayLiteral:
77
- EnforcedStyleForMultiline: consistent_comma
78
-
79
- Style/TrailingCommaInHashLiteral:
80
- EnforcedStyleForMultiline: consistent_comma
data/.rubocop_todo.yml DELETED
@@ -1,33 +0,0 @@
1
- # This configuration was generated by
2
- # `rubocop --auto-gen-config`
3
- # on 2019-07-30 09:56:31 +0800 using RuboCop version 0.73.0.
4
- # The point is for the user to remove these configuration records
5
- # one by one as the offenses are removed from the code base.
6
- # Note that changes in the inspected code, or installation of new
7
- # versions of RuboCop, may require this file to be generated again.
8
-
9
- # Offense count: 23
10
- Metrics/AbcSize:
11
- Max: 51
12
-
13
- # Offense count: 12
14
- # Configuration parameters: CountComments.
15
- Metrics/ClassLength:
16
- Max: 694
17
-
18
- # Offense count: 12
19
- Metrics/CyclomaticComplexity:
20
- Max: 15
21
-
22
- # Offense count: 6
23
- # Configuration parameters: CountKeywordArgs.
24
- Metrics/ParameterLists:
25
- Max: 7
26
-
27
- # Offense count: 8
28
- Metrics/PerceivedComplexity:
29
- Max: 17
30
-
31
- # Offense count: 86
32
- Style/Documentation:
33
- Enabled: false
data/.travis.yml DELETED
@@ -1,38 +0,0 @@
1
- language: ruby
2
-
3
- rvm:
4
- - 2.3
5
- - 2.4
6
- - 2.5
7
- - 2.6
8
- - 2.7
9
- - jruby-9.2.7.0
10
-
11
- notifications:
12
- email:
13
- on_success: never
14
-
15
- env:
16
- global:
17
- # If changing this number, please also change it in `test/test_helper.rb`.
18
- - STRIPE_MOCK_VERSION=0.101.0
19
-
20
- cache:
21
- directories:
22
- - stripe-mock
23
-
24
- before_install:
25
- # Unpack and start stripe-mock so that the test suite can talk to it
26
- - |
27
- if [ ! -d "stripe-mock/stripe-mock_${STRIPE_MOCK_VERSION}" ]; then
28
- mkdir -p stripe-mock/stripe-mock_${STRIPE_MOCK_VERSION}/
29
- curl -L "https://github.com/stripe/stripe-mock/releases/download/v${STRIPE_MOCK_VERSION}/stripe-mock_${STRIPE_MOCK_VERSION}_linux_amd64.tar.gz" -o "stripe-mock/stripe-mock_${STRIPE_MOCK_VERSION}_linux_amd64.tar.gz"
30
- tar -zxf "stripe-mock/stripe-mock_${STRIPE_MOCK_VERSION}_linux_amd64.tar.gz" -C "stripe-mock/stripe-mock_${STRIPE_MOCK_VERSION}/"
31
- fi
32
- - |
33
- stripe-mock/stripe-mock_${STRIPE_MOCK_VERSION}/stripe-mock > /dev/null &
34
- STRIPE_MOCK_PID=$!
35
- - export PATH="${PATH}:${PWD}/stripe-mock/stripe-mock_${STRIPE_MOCK_VERSION}"
36
-
37
- script:
38
- - bundle exec rake
@@ -1,7 +0,0 @@
1
- {
2
- "recommendations": [
3
- "rebornix.ruby",
4
- "misogi.ruby-rubocop",
5
- "EditorConfig.editorconfig"
6
- ]
7
- }
@@ -1,8 +0,0 @@
1
- {
2
- "editor.formatOnSave": true,
3
- "files.trimTrailingWhitespace": true,
4
-
5
- // Rubocop settings
6
- "ruby.rubocop.configFilePath": ".rubocop.yml",
7
- "ruby.rubocop.onSave": true
8
- }
@@ -1,24 +0,0 @@
1
- # File generated from our OpenAPI spec
2
- # frozen_string_literal: true
3
-
4
- module Stripe
5
- # Directly creating or retrieving BitcoinReceivers is deprecated. Please use
6
- # the Sources API instead: https://stripe.com/docs/sources/bitcoin
7
- class BitcoinReceiver < APIResource
8
- extend Stripe::APIOperations::List
9
-
10
- OBJECT_NAME = "bitcoin_receiver"
11
-
12
- def self.resource_url
13
- "/v1/bitcoin/receivers"
14
- end
15
-
16
- def resource_url
17
- if respond_to?(:customer) && !customer.nil? && customer != ""
18
- "#{Customer.resource_url}/#{CGI.escape(customer)}/sources/#{CGI.escape(id)}"
19
- else
20
- "#{self.class.resource_url}/#{CGI.escape(id)}"
21
- end
22
- end
23
- end
24
- end
@@ -1,15 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Stripe
4
- class BitcoinTransaction < APIResource
5
- # Directly retrieving BitcoinTransactions is deprecated. Please use the
6
- # Sources API instead: https://stripe.com/docs/sources/bitcoin
7
- extend Stripe::APIOperations::List
8
-
9
- OBJECT_NAME = "bitcoin_transaction"
10
-
11
- def self.resource_url
12
- "/v1/bitcoin/transactions"
13
- end
14
- end
15
- end
@@ -1,9 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Stripe
4
- module Issuing
5
- class CardDetails < Stripe::StripeObject
6
- OBJECT_NAME = "issuing.card_details"
7
- end
8
- end
9
- end
@@ -1,33 +0,0 @@
1
- # File generated from our OpenAPI spec
2
- # frozen_string_literal: true
3
-
4
- module Stripe
5
- class Order < APIResource
6
- extend Stripe::APIOperations::Create
7
- extend Stripe::APIOperations::List
8
- include Stripe::APIOperations::Save
9
-
10
- OBJECT_NAME = "order"
11
-
12
- custom_method :pay, http_verb: :post
13
- custom_method :return_order, http_verb: :post, http_path: "returns"
14
-
15
- def pay(params = {}, opts = {})
16
- request_stripe_object(
17
- method: :post,
18
- path: resource_url + "/pay",
19
- params: params,
20
- opts: opts
21
- )
22
- end
23
-
24
- def return_order(params = {}, opts = {})
25
- request_stripe_object(
26
- method: :post,
27
- path: resource_url + "/returns",
28
- params: params,
29
- opts: opts
30
- )
31
- end
32
- end
33
- end
@@ -1,10 +0,0 @@
1
- # File generated from our OpenAPI spec
2
- # frozen_string_literal: true
3
-
4
- module Stripe
5
- class OrderReturn < APIResource
6
- extend Stripe::APIOperations::List
7
-
8
- OBJECT_NAME = "order_return"
9
- end
10
- end