Compare commits

..

6 Commits

Author SHA1 Message Date
Stripe OpenAPI
7f9a370236 Update generated code for v495 2023-08-30 21:00:54 +00:00
Paul Padier
79463b2efa
Explicitly format timestamp in SignatureVerificationError message (#1262)
When interpolating a Time object in a String, Ruby calls `to_s` under the hood.

For Rails applications defining a `default` string format, this triggers deprecation warnings as of v7.0.7: https://github.com/rails/rails/pull/48555

This change fixes that by explicitly formatting the timestamp (using the same `YYYY-MM-DD HH:mm:ss` format currently implicitly used).
2023-08-21 18:14:56 -07:00
Richard Marmorstein
011f3121a5
Update CHANGELOG.md 2023-08-17 03:49:25 -07:00
Richard Marmorstein
4af7ea944c
Update CHANGELOG.md 2023-08-16 16:44:14 -07:00
Richard Marmorstein
31f300c16d Bump version to 9.0.0 2023-08-16 16:08:04 -07:00
stripe-openapi[bot]
d1d4b6e83c
Update generated code for v461 (#1260)
Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
Co-authored-by: anniel-stripe <97691964+anniel-stripe@users.noreply.github.com>
2023-08-16 22:09:20 +00:00
8 changed files with 1256 additions and 1204 deletions

File diff suppressed because it is too large Load Diff

View File

@ -1 +1 @@
v461
v495

View File

@ -1 +1 @@
8.7.0
9.0.0

View File

@ -14,6 +14,7 @@ module Stripe
# business objects
Account::OBJECT_NAME => Account,
AccountLink::OBJECT_NAME => AccountLink,
AccountSession::OBJECT_NAME => AccountSession,
ApplePayDomain::OBJECT_NAME => ApplePayDomain,
ApplicationFee::OBJECT_NAME => ApplicationFee,
ApplicationFeeRefund::OBJECT_NAME => ApplicationFeeRefund,

View File

@ -3,6 +3,7 @@
require "stripe/resources/account"
require "stripe/resources/account_link"
require "stripe/resources/account_session"
require "stripe/resources/apple_pay_domain"
require "stripe/resources/application_fee"
require "stripe/resources/application_fee_refund"

View File

@ -0,0 +1,17 @@
# File generated from our OpenAPI spec
# frozen_string_literal: true
module Stripe
# An AccountSession allows a Connect platform to grant access to a connected account in Connect embedded components.
#
# We recommend that you create an AccountSession each time you need to display an embedded component
# to your user. Do not save AccountSessions to your database as they expire relatively
# quickly, and cannot be used more than once.
#
# Related guide: [Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components)
class AccountSession < APIResource
extend Stripe::APIOperations::Create
OBJECT_NAME = "account_session"
end
end

View File

@ -1,5 +1,5 @@
# frozen_string_literal: true
module Stripe
VERSION = "8.7.0"
VERSION = "9.0.0"
end

View File

@ -108,8 +108,9 @@ module Stripe
end
if tolerance && timestamp < Time.now - tolerance
formatted_timestamp = Time.at(timestamp).strftime("%F %T")
raise SignatureVerificationError.new(
"Timestamp outside the tolerance zone (#{Time.at(timestamp)})",
"Timestamp outside the tolerance zone (#{formatted_timestamp})",
header, http_body: payload
)
end