Sha256: 265c6853dfe954df0ec1cd84891501039f63e7908403053dfebc29ec34900e48

Contents?: true

Size: 1.16 KB

Versions: 28

Compression:

Stored size: 1.16 KB

Contents

# File generated from our OpenAPI spec
# frozen_string_literal: true

module Stripe
  class CustomerBalanceTransaction < APIResource
    extend Stripe::APIOperations::List
    include Stripe::APIOperations::Save

    OBJECT_NAME = "customer_balance_transaction"

    def resource_url
      if !respond_to?(:customer) || customer.nil?
        raise NotImplementedError,
              "Customer Balance Transactions cannot be accessed without a customer ID."
      end
      "#{Customer.resource_url}/#{CGI.escape(customer)}/balance_transactions/#{CGI.escape(id)}"
    end

    def self.retrieve(_id, _opts = {})
      raise NotImplementedError,
            "Customer Balance Transactions cannot be retrieved without a customer ID. " \
            "Retrieve a Customer Balance Transaction using `Customer.retrieve_balance_transaction('cus_123', 'cbtxn_123')`"
    end

    def self.update(_id, _params = nil, _opts = nil)
      raise NotImplementedError,
            "Customer Balance Transactions cannot be retrieved without a customer ID. " \
            "Update a Customer Balance Transaction using `Customer.update_balance_transaction('cus_123', 'cbtxn_123', params)`"
    end
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
stripe-7.1.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-7.1.0.pre.beta.2 lib/stripe/resources/customer_balance_transaction.rb
stripe-7.1.0.pre.beta.1 lib/stripe/resources/customer_balance_transaction.rb
stripe-7.0.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-6.6.0.pre.beta.1 lib/stripe/resources/customer_balance_transaction.rb
stripe-6.5.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-6.4.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-6.3.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-6.2.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-6.1.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-6.0.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.55.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.54.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.53.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.52.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.50.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.49.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.48.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.47.0 lib/stripe/resources/customer_balance_transaction.rb
stripe-5.46.0 lib/stripe/resources/customer_balance_transaction.rb