diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 579e73fa..7ab08411 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1318 \ No newline at end of file +v1347 \ No newline at end of file diff --git a/lib/stripe/api_version.rb b/lib/stripe/api_version.rb index f0b789d8..cb1d8b67 100644 --- a/lib/stripe/api_version.rb +++ b/lib/stripe/api_version.rb @@ -3,6 +3,6 @@ module Stripe module ApiVersion - CURRENT = "2024-10-28.acacia" + CURRENT = "2024-11-20.acacia" end end diff --git a/lib/stripe/resources/billing/credit_grant.rb b/lib/stripe/resources/billing/credit_grant.rb index b12198e5..43839816 100644 --- a/lib/stripe/resources/billing/credit_grant.rb +++ b/lib/stripe/resources/billing/credit_grant.rb @@ -6,7 +6,6 @@ module Billing # A credit grant is an API resource that documents the allocation of some billing credits to a customer. # # Related guide: [Billing credits](https://docs.stripe.com/billing/subscriptions/usage-based/billing-credits) - # end class CreditGrant < APIResource extend Stripe::APIOperations::Create extend Stripe::APIOperations::List @@ -27,7 +26,7 @@ def self.create(params = {}, opts = {}) ) end - # Expires a credit grant + # Expires a credit grant. def expire(params = {}, opts = {}) request_stripe_object( method: :post, @@ -37,7 +36,7 @@ def expire(params = {}, opts = {}) ) end - # Expires a credit grant + # Expires a credit grant. def self.expire(id, params = {}, opts = {}) request_stripe_object( method: :post, @@ -47,7 +46,7 @@ def self.expire(id, params = {}, opts = {}) ) end - # Retrieve a list of credit grants + # Retrieve a list of credit grants. def self.list(filters = {}, opts = {}) request_stripe_object( method: :get, @@ -67,7 +66,7 @@ def self.update(id, params = {}, opts = {}) ) end - # Voids a credit grant + # Voids a credit grant. def void_grant(params = {}, opts = {}) request_stripe_object( method: :post, @@ -77,7 +76,7 @@ def void_grant(params = {}, opts = {}) ) end - # Voids a credit grant + # Voids a credit grant. def self.void_grant(id, params = {}, opts = {}) request_stripe_object( method: :post, diff --git a/lib/stripe/resources/issuing/authorization.rb b/lib/stripe/resources/issuing/authorization.rb index c21088e0..f5cffe92 100644 --- a/lib/stripe/resources/issuing/authorization.rb +++ b/lib/stripe/resources/issuing/authorization.rb @@ -192,6 +192,26 @@ def increment(params = {}, opts = {}) ) end + # Respond to a fraud challenge on a testmode Issuing authorization, simulating either a confirmation of fraud or a correction of legitimacy. + def self.respond(authorization, params = {}, opts = {}) + request_stripe_object( + method: :post, + path: format("/v1/test_helpers/issuing/authorizations/%s/fraud_challenges/respond", { authorization: CGI.escape(authorization) }), + params: params, + opts: opts + ) + end + + # Respond to a fraud challenge on a testmode Issuing authorization, simulating either a confirmation of fraud or a correction of legitimacy. + def respond(params = {}, opts = {}) + @resource.request_stripe_object( + method: :post, + path: format("/v1/test_helpers/issuing/authorizations/%s/fraud_challenges/respond", { authorization: CGI.escape(@resource["id"]) }), + params: params, + opts: opts + ) + end + # Reverse a test-mode Authorization. def self.reverse(authorization, params = {}, opts = {}) request_stripe_object( diff --git a/lib/stripe/resources/issuing/card.rb b/lib/stripe/resources/issuing/card.rb index 0166ab67..fdf8188b 100644 --- a/lib/stripe/resources/issuing/card.rb +++ b/lib/stripe/resources/issuing/card.rb @@ -3,7 +3,7 @@ module Stripe module Issuing - # You can [create physical or virtual cards](https://stripe.com/docs/issuing/cards) that are issued to cardholders. + # You can [create physical or virtual cards](https://stripe.com/docs/issuing) that are issued to cardholders. class Card < APIResource extend Stripe::APIOperations::Create extend Stripe::APIOperations::List diff --git a/lib/stripe/resources/issuing/cardholder.rb b/lib/stripe/resources/issuing/cardholder.rb index 57f04da4..24ae1441 100644 --- a/lib/stripe/resources/issuing/cardholder.rb +++ b/lib/stripe/resources/issuing/cardholder.rb @@ -5,7 +5,7 @@ module Stripe module Issuing # An Issuing `Cardholder` object represents an individual or business entity who is [issued](https://stripe.com/docs/issuing) cards. # - # Related guide: [How to create a cardholder](https://stripe.com/docs/issuing/cards#create-cardholder) + # Related guide: [How to create a cardholder](https://stripe.com/docs/issuing/cards/virtual/issue-cards#create-cardholder) class Cardholder < APIResource extend Stripe::APIOperations::Create extend Stripe::APIOperations::List diff --git a/lib/stripe/resources/subscription.rb b/lib/stripe/resources/subscription.rb index 16002f33..d0088025 100644 --- a/lib/stripe/resources/subscription.rb +++ b/lib/stripe/resources/subscription.rb @@ -127,7 +127,7 @@ def self.search_auto_paging_each(params = {}, opts = {}, &blk) # A trial starts or ends. # # - # In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how [Stripe immediately attempts payment for subscription changes](https://stripe.com/billing/subscriptions/upgrade-downgrade#immediate-payment). + # In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how [Stripe immediately attempts payment for subscription changes](https://stripe.com/docs/billing/subscriptions/upgrade-downgrade#immediate-payment). # # If you want to charge for an upgrade immediately, pass proration_behavior as always_invoice to create prorations, automatically invoice the customer for those proration adjustments, and attempt to collect payment. If you pass create_prorations, the prorations are created but not automatically invoiced. If you want to bill the customer for the prorations before the subscription's renewal date, you need to manually [invoice the customer](https://stripe.com/docs/api/invoices/create). # diff --git a/lib/stripe/services/billing/credit_grant_service.rb b/lib/stripe/services/billing/credit_grant_service.rb index 8596c420..78a92b1b 100644 --- a/lib/stripe/services/billing/credit_grant_service.rb +++ b/lib/stripe/services/billing/credit_grant_service.rb @@ -15,7 +15,7 @@ def create(params = {}, opts = {}) ) end - # Expires a credit grant + # Expires a credit grant. def expire(id, params = {}, opts = {}) request( method: :post, @@ -26,7 +26,7 @@ def expire(id, params = {}, opts = {}) ) end - # Retrieve a list of credit grants + # Retrieve a list of credit grants. def list(params = {}, opts = {}) request( method: :get, @@ -59,7 +59,7 @@ def update(id, params = {}, opts = {}) ) end - # Voids a credit grant + # Voids a credit grant. def void_grant(id, params = {}, opts = {}) request( method: :post, diff --git a/lib/stripe/services/subscription_service.rb b/lib/stripe/services/subscription_service.rb index 334aa04b..1ef8fcbb 100644 --- a/lib/stripe/services/subscription_service.rb +++ b/lib/stripe/services/subscription_service.rb @@ -107,7 +107,7 @@ def search(params = {}, opts = {}) # A trial starts or ends. # # - # In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how [Stripe immediately attempts payment for subscription changes](https://stripe.com/billing/subscriptions/upgrade-downgrade#immediate-payment). + # In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how [Stripe immediately attempts payment for subscription changes](https://stripe.com/docs/billing/subscriptions/upgrade-downgrade#immediate-payment). # # If you want to charge for an upgrade immediately, pass proration_behavior as always_invoice to create prorations, automatically invoice the customer for those proration adjustments, and attempt to collect payment. If you pass create_prorations, the prorations are created but not automatically invoiced. If you want to bill the customer for the prorations before the subscription's renewal date, you need to manually [invoice the customer](https://stripe.com/docs/api/invoices/create). # diff --git a/lib/stripe/services/test_helpers/issuing/authorization_service.rb b/lib/stripe/services/test_helpers/issuing/authorization_service.rb index e9bbc38e..45c620db 100644 --- a/lib/stripe/services/test_helpers/issuing/authorization_service.rb +++ b/lib/stripe/services/test_helpers/issuing/authorization_service.rb @@ -60,6 +60,17 @@ def increment(authorization, params = {}, opts = {}) ) end + # Respond to a fraud challenge on a testmode Issuing authorization, simulating either a confirmation of fraud or a correction of legitimacy. + def respond(authorization, params = {}, opts = {}) + request( + method: :post, + path: format("/v1/test_helpers/issuing/authorizations/%s/fraud_challenges/respond", { authorization: CGI.escape(authorization) }), + params: params, + opts: opts, + base_address: :api + ) + end + # Reverse a test-mode Authorization. def reverse(authorization, params = {}, opts = {}) request(