mirror of
https://github.com/stripe/stripe-ruby.git
synced 2025-07-30 00:01:17 -04:00
Compare commits
3 Commits
2ab25dafcc
...
14113d6ba7
Author | SHA1 | Date | |
---|---|---|---|
|
14113d6ba7 | ||
|
a685a13a67 | ||
|
bc03829f1d |
@ -1,4 +1,9 @@
|
||||
# Changelog
|
||||
## 10.6.0 - 2024-01-12
|
||||
* [#1310](https://github.com/stripe/stripe-ruby/pull/1310) Update generated code
|
||||
* Add support for new resource `CustomerSession`
|
||||
* Add support for `create` method on resource `CustomerSession`
|
||||
|
||||
## 10.5.0 - 2024-01-04
|
||||
* [#1306](https://github.com/stripe/stripe-ruby/pull/1306) Update generated code
|
||||
* Add support for `retrieve` method on resource `Tax.Registration`
|
||||
|
@ -1 +1 @@
|
||||
v742
|
||||
v769
|
@ -39,6 +39,7 @@ module Stripe
|
||||
Customer::OBJECT_NAME => Customer,
|
||||
CustomerBalanceTransaction::OBJECT_NAME => CustomerBalanceTransaction,
|
||||
CustomerCashBalanceTransaction::OBJECT_NAME => CustomerCashBalanceTransaction,
|
||||
CustomerSession::OBJECT_NAME => CustomerSession,
|
||||
Discount::OBJECT_NAME => Discount,
|
||||
Dispute::OBJECT_NAME => Dispute,
|
||||
EphemeralKey::OBJECT_NAME => EphemeralKey,
|
||||
|
@ -28,6 +28,7 @@ require "stripe/resources/credit_note_line_item"
|
||||
require "stripe/resources/customer"
|
||||
require "stripe/resources/customer_balance_transaction"
|
||||
require "stripe/resources/customer_cash_balance_transaction"
|
||||
require "stripe/resources/customer_session"
|
||||
require "stripe/resources/discount"
|
||||
require "stripe/resources/dispute"
|
||||
require "stripe/resources/ephemeral_key"
|
||||
|
@ -7,9 +7,8 @@ module Stripe
|
||||
# enabled to make live charges or receive payouts.
|
||||
#
|
||||
# For Custom accounts, the properties below are always returned. For other accounts, some properties are returned until that
|
||||
# account has started to go through Connect Onboarding. Once you create an [Account Link](https://stripe.com/docs/api/account_links)
|
||||
# for a Standard or Express account, some parameters are no longer returned. These are marked as **Custom Only** or **Custom and Express**
|
||||
# below. Learn about the differences [between accounts](https://stripe.com/docs/connect/accounts).
|
||||
# account has started to go through Connect Onboarding. Once you create an [Account Link](https://stripe.com/docs/api/account_links) or [Account Session](https://stripe.com/docs/api/account_sessions),
|
||||
# some properties are only returned for Custom accounts. Learn about the differences [between accounts](https://stripe.com/docs/connect/accounts).
|
||||
class Account < APIResource
|
||||
extend Gem::Deprecate
|
||||
extend Stripe::APIOperations::Create
|
||||
|
12
lib/stripe/resources/customer_session.rb
Normal file
12
lib/stripe/resources/customer_session.rb
Normal file
@ -0,0 +1,12 @@
|
||||
# File generated from our OpenAPI spec
|
||||
# frozen_string_literal: true
|
||||
|
||||
module Stripe
|
||||
# A customer session allows you to grant client access to Stripe's frontend SDKs (like StripeJs)
|
||||
# control over a customer.
|
||||
class CustomerSession < APIResource
|
||||
extend Stripe::APIOperations::Create
|
||||
|
||||
OBJECT_NAME = "customer_session"
|
||||
end
|
||||
end
|
@ -1,5 +1,5 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module Stripe
|
||||
VERSION = "10.5.0"
|
||||
VERSION = "10.6.0"
|
||||
end
|
||||
|
@ -395,6 +395,13 @@ module Stripe
|
||||
Stripe::CreditNote.void_credit_note("cn_xxxxxxxxxxxxx")
|
||||
assert_requested :post, "#{Stripe.api_base}/v1/credit_notes/cn_xxxxxxxxxxxxx/void?"
|
||||
end
|
||||
should "Test customer sessions post" do
|
||||
Stripe::CustomerSession.create({
|
||||
customer: "cus_123",
|
||||
components: { buy_button: { enabled: true } },
|
||||
})
|
||||
assert_requested :post, "#{Stripe.api_base}/v1/customer_sessions"
|
||||
end
|
||||
should "Test customers balance transactions get" do
|
||||
Stripe::Customer.list_balance_transactions("cus_xxxxxxxxxxxxx", { limit: 3 })
|
||||
assert_requested :get, "#{Stripe.api_base}/v1/customers/cus_xxxxxxxxxxxxx/balance_transactions?limit=3"
|
||||
|
Loading…
x
Reference in New Issue
Block a user