Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merging from origin/master to sdk-release/next-major #1371

Merged
merged 3 commits into from
Mar 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
# Changelog
## 10.13.0 - 2024-03-21
* [#1367](https://github.com/stripe/stripe-ruby/pull/1367) Update generated code
* Add support for new resources `ConfirmationToken` and `Forwarding.Request`
* Add support for `retrieve` method on resource `ConfirmationToken`
* Add support for `create`, `list`, and `retrieve` methods on resource `Request`
* [#1362](https://github.com/stripe/stripe-ruby/pull/1362) Exclude sorbet directory and tapioca script when packing gem

## 10.12.0 - 2024-03-14
* [#1359](https://github.com/stripe/stripe-ruby/pull/1359) Update generated code
* Add support for new resources `Issuing.PersonalizationDesign` and `Issuing.PhysicalBundle`
Expand Down
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v878
v889
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
10.12.0
10.13.0
2 changes: 2 additions & 0 deletions lib/stripe/object_types.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ def self.object_names_to_classes
Climate::Order.object_name => Climate::Order,
Climate::Product.object_name => Climate::Product,
Climate::Supplier.object_name => Climate::Supplier,
ConfirmationToken.object_name => ConfirmationToken,
CountrySpec.object_name => CountrySpec,
Coupon.object_name => Coupon,
CreditNote.object_name => CreditNote,
Expand All @@ -53,6 +54,7 @@ def self.object_names_to_classes
FinancialConnections::AccountOwnership.object_name => FinancialConnections::AccountOwnership,
FinancialConnections::Session.object_name => FinancialConnections::Session,
FinancialConnections::Transaction.object_name => FinancialConnections::Transaction,
Forwarding::Request.object_name => Forwarding::Request,
FundingInstructions.object_name => FundingInstructions,
Identity::VerificationReport.object_name => Identity::VerificationReport,
Identity::VerificationSession.object_name => Identity::VerificationSession,
Expand Down
2 changes: 2 additions & 0 deletions lib/stripe/resources.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
require "stripe/resources/climate/order"
require "stripe/resources/climate/product"
require "stripe/resources/climate/supplier"
require "stripe/resources/confirmation_token"
require "stripe/resources/country_spec"
require "stripe/resources/coupon"
require "stripe/resources/credit_note"
Expand All @@ -41,6 +42,7 @@
require "stripe/resources/financial_connections/account_ownership"
require "stripe/resources/financial_connections/session"
require "stripe/resources/financial_connections/transaction"
require "stripe/resources/forwarding/request"
require "stripe/resources/funding_instructions"
require "stripe/resources/identity/verification_report"
require "stripe/resources/identity/verification_session"
Expand Down
37 changes: 37 additions & 0 deletions lib/stripe/resources/confirmation_token.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# File generated from our OpenAPI spec
# frozen_string_literal: true

module Stripe
# ConfirmationTokens help transport client side data collected by Stripe JS over
# to your server for confirming a PaymentIntent or SetupIntent. If the confirmation
# is successful, values present on the ConfirmationToken are written onto the Intent.
#
# To learn more or request access, visit the related guided: [Finalize payments on the server using Confirmation Tokens](https://stripe.com/docs/payments/finalize-payments-on-the-server-confirmation-tokens).
class ConfirmationToken < APIResource
OBJECT_NAME = "confirmation_token"
def self.object_name
"confirmation_token"
end

def test_helpers
TestHelpers.new(self)
end

class TestHelpers < APIResourceTestHelpers
RESOURCE_CLASS = ConfirmationToken
def self.resource_class
"ConfirmationToken"
end

# Creates a test mode Confirmation Token server side for your integration tests.
def self.create(params = {}, opts = {})
request_stripe_object(
method: :post,
path: "/v1/test_helpers/confirmation_tokens",
params: params,
opts: opts
)
end
end
end
end
50 changes: 50 additions & 0 deletions lib/stripe/resources/forwarding/request.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# File generated from our OpenAPI spec
# frozen_string_literal: true

module Stripe
module Forwarding
# Instructs Stripe to make a request on your behalf using the destination URL and HTTP method in the config.
# A config is set up for each destination URL by Stripe at the time of onboarding. Stripe verifies requests with
# your credentials in the config, and injects card details from the payment_method into the request.
#
# Stripe redacts all sensitive fields and headers, including authentication credentials and card numbers,
# before storing the request and response data in the forwarding Request object, which are subject to a
# 30-day retention period.
#
# You can provide a Stripe idempotency key to make sure that requests with the same key result in only one
# outbound request. The Stripe idempotency key provided should be unique and different from any idempotency
# keys provided on the underlying third-party request.
#
# Forwarding Requests are synchronous requests that return a response or time out according to
# Stripe's limits.
class Request < APIResource
extend Stripe::APIOperations::Create
extend Stripe::APIOperations::List

OBJECT_NAME = "forwarding.request"
def self.object_name
"forwarding.request"
end

# Creates a ForwardingRequest object.
def self.create(params = {}, opts = {})
request_stripe_object(
method: :post,
path: "/v1/forwarding/requests",
params: params,
opts: opts
)
end

# Lists all ForwardingRequest objects.
def self.list(filters = {}, opts = {})
request_stripe_object(
method: :get,
path: "/v1/forwarding/requests",
params: filters,
opts: opts
)
end
end
end
end
2 changes: 1 addition & 1 deletion lib/stripe/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Stripe
VERSION = "10.12.0"
VERSION = "10.13.0"
end
Loading