module Stripe::APIOperations::Save::ClassMethods
def update(id, params = {}, opts = {})
idempotency_key to be passed in the request headers, or for the
object values) to be added to the request. E.g. to allow for an
* +opts+ - A Hash of additional options (separate from the params /
* +params+ - A hash of parameters to pass to the API
* +id+ - ID of the resource to update.
==== Attributes
Updates the identified resource with the passed in parameters.
Updates an API resource
def update(id, params = {}, opts = {}) params.each_key do |k| if protected_fields.include?(k) raise ArgumentError, "Cannot update protected field: #{k}" end end resp, opts = request(:post, "#{resource_url}/#{id}", params, opts) Util.convert_to_stripe_object(resp.data, opts) end