Sha256: 8e7206931e52c118584073b4df8531723a3b09d4542d6ac26f3666de72151eb8
Contents?: true
Size: 616 Bytes
Versions: 5
Compression:
Stored size: 616 Bytes
Contents
module Stripe class Card < APIResource include Stripe::APIOperations::Update include Stripe::APIOperations::Delete include Stripe::APIOperations::List def url if respond_to?(:recipient) "#{Recipient.url}/#{CGI.escape(recipient)}/cards/#{CGI.escape(id)}" elsif respond_to?(:customer) "#{Customer.url}/#{CGI.escape(customer)}/sources/#{CGI.escape(id)}" end end def self.retrieve(id, opts=nil) raise NotImplementedError.new("Cards cannot be retrieved without a customer ID. Retrieve a card using customer.cards.retrieve('card_id')") end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
stripe-1.21.0 | lib/stripe/card.rb |
stripe-1.20.4 | lib/stripe/card.rb |
stripe-1.20.3 | lib/stripe/card.rb |
stripe-1.20.2 | lib/stripe/card.rb |
stripe-1.20.1 | lib/stripe/card.rb |