From c4f115226f98e0bb41fdd46a94a7420ef790b1ab Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Fri, 29 Mar 2024 17:33:06 +0000 Subject: [PATCH] Update generated code for v917 --- OPENAPI_VERSION | 2 +- lib/stripe/resources/entitlements/feature.rb | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 3fbb4182..51d7ba28 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v914 \ No newline at end of file +v917 \ No newline at end of file diff --git a/lib/stripe/resources/entitlements/feature.rb b/lib/stripe/resources/entitlements/feature.rb index 45ee6020..722d33a4 100644 --- a/lib/stripe/resources/entitlements/feature.rb +++ b/lib/stripe/resources/entitlements/feature.rb @@ -8,6 +8,7 @@ module Stripe class Feature < APIResource extend Stripe::APIOperations::Create extend Stripe::APIOperations::List + include Stripe::APIOperations::Save OBJECT_NAME = "entitlements.feature" def self.object_name @@ -33,6 +34,16 @@ module Stripe opts: opts ) end + + # Update a feature's metadata or permanently deactivate it. + def self.update(id, params = {}, opts = {}) + request_stripe_object( + method: :post, + path: format("/v1/entitlements/features/%s", { id: CGI.escape(id) }), + params: params, + opts: opts + ) + end end end end