mirror of
https://github.com/stripe/stripe-ruby.git
synced 2025-07-16 00:00:46 -04:00
Compare commits
No commits in common. "5ea85d08677c761ee3f2479daccd173b549deaa9" and "094574d2fee2ad849c8923674628b90bdc7aa120" have entirely different histories.
5ea85d0867
...
094574d2fe
@ -1,10 +1,5 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
## 8.1.0-beta.4 - 2023-01-05
|
|
||||||
* [#1164](https://github.com/stripe/stripe-ruby/pull/1164) API Updates for beta branch
|
|
||||||
* Updated stable APIs to the latest version
|
|
||||||
* Add support for `mark_stale_quote` method on resource `Quote`
|
|
||||||
|
|
||||||
## 8.1.0-beta.3 - 2022-12-22
|
## 8.1.0-beta.3 - 2022-12-22
|
||||||
* [#1158](https://github.com/stripe/stripe-ruby/pull/1158) API Updates for beta branch
|
* [#1158](https://github.com/stripe/stripe-ruby/pull/1158) API Updates for beta branch
|
||||||
* Updated stable APIs to the latest version
|
* Updated stable APIs to the latest version
|
||||||
|
@ -1 +1 @@
|
|||||||
v217
|
v216
|
@ -64,6 +64,7 @@ module Stripe
|
|||||||
|
|
||||||
nested_resource_class_methods :external_account,
|
nested_resource_class_methods :external_account,
|
||||||
operations: %i[create retrieve update delete list]
|
operations: %i[create retrieve update delete list]
|
||||||
|
|
||||||
nested_resource_class_methods :login_link, operations: %i[create]
|
nested_resource_class_methods :login_link, operations: %i[create]
|
||||||
|
|
||||||
def resource_url
|
def resource_url
|
||||||
|
@ -74,15 +74,6 @@ module Stripe
|
|||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
def mark_stale_quote(params = {}, opts = {})
|
|
||||||
request_stripe_object(
|
|
||||||
method: :post,
|
|
||||||
path: format("/v1/quotes/%<quote>s/mark_stale", { quote: CGI.escape(self["id"]) }),
|
|
||||||
params: params,
|
|
||||||
opts: opts
|
|
||||||
)
|
|
||||||
end
|
|
||||||
|
|
||||||
def preview_invoice_lines(params = {}, opts = {})
|
def preview_invoice_lines(params = {}, opts = {})
|
||||||
request_stripe_object(
|
request_stripe_object(
|
||||||
method: :get,
|
method: :get,
|
||||||
@ -182,15 +173,6 @@ module Stripe
|
|||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.mark_stale_quote(quote, params = {}, opts = {})
|
|
||||||
request_stripe_object(
|
|
||||||
method: :post,
|
|
||||||
path: format("/v1/quotes/%<quote>s/mark_stale", { quote: CGI.escape(quote) }),
|
|
||||||
params: params,
|
|
||||||
opts: opts
|
|
||||||
)
|
|
||||||
end
|
|
||||||
|
|
||||||
def self.preview_invoice_lines(quote, params = {}, opts = {})
|
def self.preview_invoice_lines(quote, params = {}, opts = {})
|
||||||
request_stripe_object(
|
request_stripe_object(
|
||||||
method: :get,
|
method: :get,
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
# frozen_string_literal: true
|
# frozen_string_literal: true
|
||||||
|
|
||||||
module Stripe
|
module Stripe
|
||||||
VERSION = "8.1.0-beta.4"
|
VERSION = "8.1.0-beta.3"
|
||||||
end
|
end
|
||||||
|
@ -32,12 +32,6 @@ module Stripe
|
|||||||
assert_requested :get, "#{Stripe.api_base}/v1/accounts?limit=3"
|
assert_requested :get, "#{Stripe.api_base}/v1/accounts?limit=3"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
context "Account.persons" do
|
|
||||||
should "support requests with args: limit, parent_id" do
|
|
||||||
Stripe::Account.persons("acct_xxxxxxxxxxxxx", { limit: 3 })
|
|
||||||
assert_requested :get, "#{Stripe.api_base}/v1/accounts/acct_xxxxxxxxxxxxx/persons?limit=3"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
context "Account.reject" do
|
context "Account.reject" do
|
||||||
should "support requests with args: reason, id" do
|
should "support requests with args: reason, id" do
|
||||||
Stripe::Account.reject("acct_xxxxxxxxxxxxx", { reason: "fraud" })
|
Stripe::Account.reject("acct_xxxxxxxxxxxxx", { reason: "fraud" })
|
||||||
@ -84,31 +78,6 @@ module Stripe
|
|||||||
assert_requested :get, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx?"
|
assert_requested :get, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx?"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
context "ApplicationFeeRefund.list" do
|
|
||||||
should "support requests with args: limit, parent_id" do
|
|
||||||
Stripe::ApplicationFee.list_refunds("fee_xxxxxxxxxxxxx", { limit: 3 })
|
|
||||||
assert_requested :get, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx/refunds?limit=3"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
context "ApplicationFeeRefund.retrieve" do
|
|
||||||
should "support requests with args: parent_id, id" do
|
|
||||||
Stripe::ApplicationFee.retrieve_refund(
|
|
||||||
"fee_xxxxxxxxxxxxx",
|
|
||||||
"fr_xxxxxxxxxxxxx"
|
|
||||||
)
|
|
||||||
assert_requested :get, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx/refunds/fr_xxxxxxxxxxxxx?"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
context "ApplicationFeeRefund.update" do
|
|
||||||
should "support requests with args: metadata, parent_id, id" do
|
|
||||||
Stripe::ApplicationFee.update_refund(
|
|
||||||
"fee_xxxxxxxxxxxxx",
|
|
||||||
"fr_xxxxxxxxxxxxx",
|
|
||||||
{ metadata: { order_id: "6735" } }
|
|
||||||
)
|
|
||||||
assert_requested :post, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx/refunds/fr_xxxxxxxxxxxxx"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
context "Apps.Secret.create" do
|
context "Apps.Secret.create" do
|
||||||
should "support requests with args: name, payload, scope" do
|
should "support requests with args: name, payload, scope" do
|
||||||
Stripe::Apps::Secret.create(
|
Stripe::Apps::Secret.create(
|
||||||
@ -602,6 +571,31 @@ module Stripe
|
|||||||
assert_requested :get, "#{Stripe.api_base}/v1/events/evt_xxxxxxxxxxxxx?"
|
assert_requested :get, "#{Stripe.api_base}/v1/events/evt_xxxxxxxxxxxxx?"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
context "FeeRefund.list" do
|
||||||
|
should "support requests with args: limit, parent_id" do
|
||||||
|
Stripe::ApplicationFee.list_refunds("fee_xxxxxxxxxxxxx", { limit: 3 })
|
||||||
|
assert_requested :get, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx/refunds?limit=3"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
context "FeeRefund.retrieve" do
|
||||||
|
should "support requests with args: parent_id, id" do
|
||||||
|
Stripe::ApplicationFee.retrieve_refund(
|
||||||
|
"fee_xxxxxxxxxxxxx",
|
||||||
|
"fr_xxxxxxxxxxxxx"
|
||||||
|
)
|
||||||
|
assert_requested :get, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx/refunds/fr_xxxxxxxxxxxxx?"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
context "FeeRefund.update" do
|
||||||
|
should "support requests with args: metadata, parent_id, id" do
|
||||||
|
Stripe::ApplicationFee.update_refund(
|
||||||
|
"fee_xxxxxxxxxxxxx",
|
||||||
|
"fr_xxxxxxxxxxxxx",
|
||||||
|
{ metadata: { order_id: "6735" } }
|
||||||
|
)
|
||||||
|
assert_requested :post, "#{Stripe.api_base}/v1/application_fees/fee_xxxxxxxxxxxxx/refunds/fr_xxxxxxxxxxxxx"
|
||||||
|
end
|
||||||
|
end
|
||||||
context "File.list" do
|
context "File.list" do
|
||||||
should "support requests with args: limit" do
|
should "support requests with args: limit" do
|
||||||
Stripe::File.list({ limit: 3 })
|
Stripe::File.list({ limit: 3 })
|
||||||
@ -1300,6 +1294,12 @@ module Stripe
|
|||||||
assert_requested :post, "#{Stripe.api_base}/v1/payouts/po_xxxxxxxxxxxxx"
|
assert_requested :post, "#{Stripe.api_base}/v1/payouts/po_xxxxxxxxxxxxx"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
context "Person.list" do
|
||||||
|
should "support requests with args: limit, parent_id" do
|
||||||
|
Stripe::Account.list_persons("acct_xxxxxxxxxxxxx", { limit: 3 })
|
||||||
|
assert_requested :get, "#{Stripe.api_base}/v1/accounts/acct_xxxxxxxxxxxxx/persons?limit=3"
|
||||||
|
end
|
||||||
|
end
|
||||||
context "Person.retrieve" do
|
context "Person.retrieve" do
|
||||||
should "support requests with args: parent_id, id" do
|
should "support requests with args: parent_id, id" do
|
||||||
Stripe::Account.retrieve_person(
|
Stripe::Account.retrieve_person(
|
||||||
@ -1684,31 +1684,6 @@ module Stripe
|
|||||||
assert_requested :get, "#{Stripe.api_base}/v1/reporting/report_types/balance.summary.1?"
|
assert_requested :get, "#{Stripe.api_base}/v1/reporting/report_types/balance.summary.1?"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
context "Reversal.list" do
|
|
||||||
should "support requests with args: limit, parent_id" do
|
|
||||||
Stripe::Transfer.list_reversals("tr_xxxxxxxxxxxxx", { limit: 3 })
|
|
||||||
assert_requested :get, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx/reversals?limit=3"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
context "Reversal.retrieve" do
|
|
||||||
should "support requests with args: parent_id, id" do
|
|
||||||
Stripe::Transfer.retrieve_reversal(
|
|
||||||
"tr_xxxxxxxxxxxxx",
|
|
||||||
"trr_xxxxxxxxxxxxx"
|
|
||||||
)
|
|
||||||
assert_requested :get, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx/reversals/trr_xxxxxxxxxxxxx?"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
context "Reversal.update" do
|
|
||||||
should "support requests with args: metadata, parent_id, id" do
|
|
||||||
Stripe::Transfer.update_reversal(
|
|
||||||
"tr_xxxxxxxxxxxxx",
|
|
||||||
"trr_xxxxxxxxxxxxx",
|
|
||||||
{ metadata: { order_id: "6735" } }
|
|
||||||
)
|
|
||||||
assert_requested :post, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx/reversals/trr_xxxxxxxxxxxxx"
|
|
||||||
end
|
|
||||||
end
|
|
||||||
context "Review.approve" do
|
context "Review.approve" do
|
||||||
should "support requests with args: id" do
|
should "support requests with args: id" do
|
||||||
Stripe::Review.approve("prv_xxxxxxxxxxxxx")
|
Stripe::Review.approve("prv_xxxxxxxxxxxxx")
|
||||||
@ -2408,6 +2383,31 @@ module Stripe
|
|||||||
assert_requested :post, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx"
|
assert_requested :post, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
context "TransferReversal.list" do
|
||||||
|
should "support requests with args: limit, parent_id" do
|
||||||
|
Stripe::Transfer.list_reversals("tr_xxxxxxxxxxxxx", { limit: 3 })
|
||||||
|
assert_requested :get, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx/reversals?limit=3"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
context "TransferReversal.retrieve" do
|
||||||
|
should "support requests with args: parent_id, id" do
|
||||||
|
Stripe::Transfer.retrieve_reversal(
|
||||||
|
"tr_xxxxxxxxxxxxx",
|
||||||
|
"trr_xxxxxxxxxxxxx"
|
||||||
|
)
|
||||||
|
assert_requested :get, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx/reversals/trr_xxxxxxxxxxxxx?"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
context "TransferReversal.update" do
|
||||||
|
should "support requests with args: metadata, parent_id, id" do
|
||||||
|
Stripe::Transfer.update_reversal(
|
||||||
|
"tr_xxxxxxxxxxxxx",
|
||||||
|
"trr_xxxxxxxxxxxxx",
|
||||||
|
{ metadata: { order_id: "6735" } }
|
||||||
|
)
|
||||||
|
assert_requested :post, "#{Stripe.api_base}/v1/transfers/tr_xxxxxxxxxxxxx/reversals/trr_xxxxxxxxxxxxx"
|
||||||
|
end
|
||||||
|
end
|
||||||
context "Treasury.CreditReversal.create" do
|
context "Treasury.CreditReversal.create" do
|
||||||
should "support requests with args: received_credit" do
|
should "support requests with args: received_credit" do
|
||||||
Stripe::Treasury::CreditReversal.create(
|
Stripe::Treasury::CreditReversal.create(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user