braintree 2.31.0 → 2.32.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (51) hide show
  1. data/README.rdoc +2 -2
  2. data/lib/braintree.rb +12 -0
  3. data/lib/braintree/client_token.rb +5 -0
  4. data/lib/braintree/client_token_gateway.rb +2 -1
  5. data/lib/braintree/configuration.rb +1 -1
  6. data/lib/braintree/credit_card.rb +1 -1
  7. data/lib/braintree/credit_card_gateway.rb +3 -3
  8. data/lib/braintree/customer.rb +18 -4
  9. data/lib/braintree/customer_gateway.rb +2 -2
  10. data/lib/braintree/customer_search.rb +1 -0
  11. data/lib/braintree/error_codes.rb +81 -14
  12. data/lib/braintree/exceptions.rb +2 -0
  13. data/lib/braintree/gateway.rb +16 -0
  14. data/lib/braintree/payment_instrument_type.rb +7 -0
  15. data/lib/braintree/payment_method.rb +17 -0
  16. data/lib/braintree/payment_method_gateway.rb +58 -0
  17. data/lib/braintree/paypal_account.rb +47 -0
  18. data/lib/braintree/paypal_account_gateway.rb +41 -0
  19. data/lib/braintree/sepa_bank_account.rb +34 -0
  20. data/lib/braintree/sepa_bank_account_gateway.rb +16 -0
  21. data/lib/braintree/successful_result.rb +1 -1
  22. data/lib/braintree/test/nonce.rb +10 -0
  23. data/lib/braintree/test_transaction.rb +15 -0
  24. data/lib/braintree/testing_gateway.rb +35 -0
  25. data/lib/braintree/transaction.rb +6 -0
  26. data/lib/braintree/transaction/paypal_details.rb +14 -0
  27. data/lib/braintree/transaction_gateway.rb +3 -1
  28. data/lib/braintree/transaction_search.rb +4 -0
  29. data/lib/braintree/unknown_payment_method.rb +20 -0
  30. data/lib/braintree/version.rb +2 -2
  31. data/lib/braintree/webhook_testing_gateway.rb +1 -1
  32. data/spec/integration/braintree/client_api/client_token_spec.rb +80 -17
  33. data/spec/integration/braintree/client_api/spec_helper.rb +93 -10
  34. data/spec/integration/braintree/credit_card_spec.rb +28 -27
  35. data/spec/integration/braintree/customer_search_spec.rb +23 -0
  36. data/spec/integration/braintree/customer_spec.rb +83 -1
  37. data/spec/integration/braintree/payment_method_spec.rb +315 -0
  38. data/spec/integration/braintree/paypal_account_spec.rb +188 -0
  39. data/spec/integration/braintree/subscription_spec.rb +50 -20
  40. data/spec/integration/braintree/test_transaction_spec.rb +104 -0
  41. data/spec/integration/braintree/transaction_search_spec.rb +60 -0
  42. data/spec/integration/braintree/transaction_spec.rb +583 -8
  43. data/spec/integration/spec_helper.rb +22 -0
  44. data/spec/spec_helper.rb +8 -2
  45. data/spec/unit/braintree/customer_spec.rb +24 -4
  46. data/spec/unit/braintree/payment_method_spec.rb +25 -0
  47. data/spec/unit/braintree/paypal_account_spec.rb +31 -0
  48. data/spec/unit/braintree/unknown_payment_method_spec.rb +29 -0
  49. metadata +141 -120
  50. checksums.yaml +0 -7
  51. data/spec/httpsd.pid +0 -1
@@ -45,7 +45,7 @@ Example of using non-bang method:
45
45
 
46
46
  result = Braintree::Customer.create(:first_name => "Josh")
47
47
  if result.success?
48
- puts "Created customer #{result.customer.id}
48
+ puts "Created customer #{result.customer.id}"
49
49
  else
50
50
  puts "Validations failed"
51
51
  result.errors.for(:customer).each do |error|
@@ -57,7 +57,7 @@ Example of using bang method:
57
57
 
58
58
  begin
59
59
  customer = Braintree::Customer.create!(:first_name => "Josh")
60
- puts "Created customer #{customer.id}
60
+ puts "Created customer #{customer.id}"
61
61
  rescue Braintree::ValidationsFailed
62
62
  puts "Validations failed"
63
63
  end
@@ -53,11 +53,18 @@ require "braintree/merchant_account/individual_details"
53
53
  require "braintree/merchant_account/business_details"
54
54
  require "braintree/merchant_account/funding_details"
55
55
  require "braintree/merchant_account/address_details"
56
+ require "braintree/payment_instrument_type"
57
+ require "braintree/payment_method"
58
+ require "braintree/payment_method_gateway"
59
+ require "braintree/paypal_account"
60
+ require "braintree/paypal_account_gateway"
56
61
  require "braintree/plan"
57
62
  require "braintree/plan_gateway"
58
63
  require "braintree/settlement_batch_summary"
59
64
  require "braintree/settlement_batch_summary_gateway"
60
65
  require "braintree/resource_collection"
66
+ require "braintree/sepa_bank_account"
67
+ require "braintree/sepa_bank_account_gateway"
61
68
  require "braintree/sha256_digest"
62
69
  require "braintree/signature_service"
63
70
  require "braintree/subscription"
@@ -67,16 +74,21 @@ require "braintree/successful_result"
67
74
  require "braintree/test/credit_card"
68
75
  require "braintree/test/merchant_account"
69
76
  require "braintree/test/venmo_sdk"
77
+ require "braintree/test/nonce"
70
78
  require "braintree/test/transaction_amounts"
79
+ require "braintree/testing_gateway"
71
80
  require "braintree/transaction"
81
+ require "braintree/test_transaction"
72
82
  require "braintree/transaction/address_details"
73
83
  require "braintree/transaction/credit_card_details"
74
84
  require "braintree/transaction/customer_details"
75
85
  require "braintree/transaction/disbursement_details"
86
+ require "braintree/transaction/paypal_details"
76
87
  require "braintree/transaction/subscription_details"
77
88
  require "braintree/transaction_gateway"
78
89
  require "braintree/transaction_search"
79
90
  require "braintree/transaction/status_details"
91
+ require "braintree/unknown_payment_method"
80
92
  require "braintree/disbursement"
81
93
  require "braintree/transparent_redirect"
82
94
  require "braintree/transparent_redirect_gateway"
@@ -2,8 +2,13 @@ require 'json'
2
2
 
3
3
  module Braintree
4
4
  module ClientToken
5
+ DEFAULT_VERSION = 2
6
+
5
7
  def self.generate(options={})
6
8
  _validate_options(options)
9
+
10
+ options[:version] ||= DEFAULT_VERSION
11
+
7
12
  Configuration.gateway.client_token.generate(options)
8
13
  end
9
14
 
@@ -22,7 +22,8 @@ module Braintree
22
22
 
23
23
  def self._generate_signature # :nodoc:
24
24
  [
25
- :customer_id, :proxy_merchant_id,
25
+ :address_id, :customer_id, :proxy_merchant_id, :merchant_account_id,
26
+ :version, :sepa_mandate_acceptance_location, :sepa_mandate_type,
26
27
  {:options => [:make_default, :verify_card, :fail_on_duplicate_payment_method]}
27
28
  ]
28
29
  end
@@ -1,7 +1,7 @@
1
1
  module Braintree
2
2
  # See http://www.braintreepayments.com/docs/ruby
3
3
  class Configuration
4
- API_VERSION = "3" # :nodoc:
4
+ API_VERSION = "4" # :nodoc:
5
5
  DEFAULT_ENDPOINT = "api" # :nodoc:
6
6
 
7
7
  class << self
@@ -165,7 +165,7 @@ module Braintree
165
165
  @gateway.credit_card.delete(token)
166
166
  end
167
167
 
168
- # Returns true if this credit card is the customer's default.
168
+ # Returns true if this credit card is the customer's default payment method.
169
169
  def default?
170
170
  @default
171
171
  end
@@ -25,7 +25,7 @@ module Braintree
25
25
  end
26
26
 
27
27
  def delete(token)
28
- @config.http.delete("/payment_methods/#{token}")
28
+ @config.http.delete("/payment_methods/credit_card/#{token}")
29
29
  end
30
30
 
31
31
  def expired(options = {})
@@ -42,7 +42,7 @@ module Braintree
42
42
 
43
43
  def find(token)
44
44
  raise ArgumentError if token.nil? || token.to_s.strip == ""
45
- response = @config.http.get "/payment_methods/#{token}"
45
+ response = @config.http.get "/payment_methods/credit_card/#{token}"
46
46
  CreditCard._new(@gateway, response[:credit_card])
47
47
  rescue NotFoundError
48
48
  raise NotFoundError, "payment method with token #{token.inspect} not found"
@@ -58,7 +58,7 @@ module Braintree
58
58
 
59
59
  def update(token, attributes)
60
60
  Util.verify_keys(CreditCardGateway._update_signature, attributes)
61
- _do_update(:put, "/payment_methods/#{token}", :credit_card => attributes)
61
+ _do_update(:put, "/payment_methods/credit_card/#{token}", :credit_card => attributes)
62
62
  end
63
63
 
64
64
  # Deprecated
@@ -4,7 +4,7 @@ module Braintree
4
4
  include BaseModule
5
5
 
6
6
  attr_reader :addresses, :company, :created_at, :credit_cards, :email, :fax, :first_name, :id, :last_name,
7
- :phone, :updated_at, :website, :custom_fields
7
+ :phone, :updated_at, :website, :custom_fields, :paypal_accounts
8
8
 
9
9
  # See http://www.braintreepayments.com/docs/ruby/customers/search
10
10
  def self.all
@@ -107,6 +107,7 @@ module Braintree
107
107
  @gateway = gateway
108
108
  set_instance_variables_from_hash(attributes)
109
109
  @credit_cards = (@credit_cards || []).map { |pm| CreditCard._new gateway, pm }
110
+ @paypal_accounts = (@paypal_accounts || []).map { |pm| PayPalAccount._new gateway, pm }
110
111
  @addresses = (@addresses || []).map { |addr| Address._new gateway, addr }
111
112
  @custom_fields = attributes[:custom_fields].is_a?(Hash) ? attributes[:custom_fields] : {}
112
113
  end
@@ -121,9 +122,17 @@ module Braintree
121
122
  return_object_or_raise(:transaction) { credit(transaction_attributes) }
122
123
  end
123
124
 
124
- # Returns the default credit card of the customer
125
+ # Deprecated. Use Braintree::Customer.default_payment_method
126
+ #
127
+ # Returns the customer's default credit card.
125
128
  def default_credit_card
126
- @credit_cards.find {|credit_card| credit_card.default? }
129
+ warn "[DEPRECATED] Customer#default_credit_card is deprecated. Please use Customer#default_payment_method"
130
+ @credit_cards.find { |credit_card| credit_card.default? }
131
+ end
132
+
133
+ # Returns the customer's default payment method.
134
+ def default_payment_method
135
+ payment_methods.find { |payment_instrument| payment_instrument.default? }
127
136
  end
128
137
 
129
138
  # See http://www.braintreepayments.com/docs/ruby/customers/delete
@@ -131,9 +140,14 @@ module Braintree
131
140
  @gateway.customer.delete(id)
132
141
  end
133
142
 
143
+ # Returns the customer's payment methods
144
+ def payment_methods
145
+ @credit_cards.dup + @paypal_accounts.dup
146
+ end
147
+
134
148
  def inspect # :nodoc:
135
149
  first = [:id]
136
- last = [:addresses, :credit_cards]
150
+ last = [:addresses, :credit_cards, :paypal_accounts]
137
151
  order = first + (self.class._attributes - first - last) + last
138
152
  nice_attributes = order.map do |attr|
139
153
  "#{attr}: #{send(attr).inspect}"
@@ -74,7 +74,7 @@ module Braintree
74
74
  credit_card_signature = CreditCardGateway._create_signature - [:customer_id]
75
75
  [
76
76
  :company, :email, :fax, :first_name, :id, :last_name, :phone, :website,
77
- :device_data,
77
+ :device_data, :payment_method_nonce,
78
78
  {:credit_card => credit_card_signature},
79
79
  {:custom_fields => :_any_key_}
80
80
  ]
@@ -123,7 +123,7 @@ module Braintree
123
123
  credit_card_options[:options] << :update_existing_token
124
124
  [
125
125
  :company, :email, :fax, :first_name, :id, :last_name, :phone, :website,
126
- :device_data,
126
+ :device_data, :payment_method_nonce,
127
127
  {:credit_card => credit_card_signature},
128
128
  {:custom_fields => :_any_key_}
129
129
  ]
@@ -17,6 +17,7 @@ module Braintree
17
17
  :id,
18
18
  :last_name,
19
19
  :payment_method_token,
20
+ :paypal_account_email,
20
21
  :phone,
21
22
  :website
22
23
  )
@@ -37,35 +37,43 @@ module Braintree
37
37
  module CreditCard
38
38
  BillingAddressConflict = "91701"
39
39
  BillingAddressIdIsInvalid = "91702"
40
- CustomerIdIsRequired = "91704"
41
- CustomerIdIsInvalid = "91705"
42
- ExpirationDateConflict = "91708"
43
- TokenFormatIsInvalid = "91718"
44
- TokenIsInUse = "91719"
45
- TokenIsTooLong = "91720"
46
- TokenIsNotAllowed = "91721"
47
- TokenIsRequired = "91722"
40
+ CannotUpdateCardUsingPaymentMethodNonce = "91735"
48
41
  CardholderNameIsTooLong = "81723"
49
42
  CreditCardTypeIsNotAccepted = "81703"
50
43
  CreditCardTypeIsNotAcceptedBySubscriptionMerchantAccount = "81718"
51
- CvvIsRequired = "81706"
44
+ CustomerIdIsInvalid = "91705"
45
+ CustomerIdIsRequired = "91704"
52
46
  CvvIsInvalid = "81707"
47
+ CvvIsRequired = "81706"
48
+ CvvVerificationFailed = "81736"
49
+ PostalCodeVerificationFailed = "81737"
53
50
  DuplicateCardExists = "81724"
54
- ExpirationDateIsRequired = "81709"
51
+ ExpirationDateConflict = "91708"
55
52
  ExpirationDateIsInvalid = "81710"
53
+ ExpirationDateIsRequired = "81709"
56
54
  ExpirationDateYearIsInvalid = "81711"
57
55
  ExpirationMonthIsInvalid = "81712"
58
56
  ExpirationYearIsInvalid = "81713"
59
57
  InvalidVenmoSDKPaymentMethodCode = "91727"
60
- NumberIsRequired = "81714"
61
58
  NumberIsInvalid = "81715"
59
+ NumberIsRequired = "81714"
62
60
  NumberLengthIsInvalid = "81716"
63
61
  NumberMustBeTestNumber = "81717"
64
62
  PaymentMethodConflict = "81725"
63
+ PaymentMethodNonceCardTypeIsNotAccepted = "91734"
64
+ PaymentMethodNonceConsumed = "91731"
65
+ PaymentMethodNonceLocked = "91733"
66
+ PaymentMethodNonceUnknown = "91732"
67
+ TokenFormatIsInvalid = "91718"
68
+ TokenIsInUse = "91719"
69
+ TokenIsNotAllowed = "91721"
70
+ TokenIsRequired = "91722"
71
+ TokenIsTooLong = "91720"
65
72
  VenmoSDKPaymentMethodCodeCardTypeIsNotAccepted = "91726"
66
73
  VerificationNotSupportedOnThisMerchantAccount = "91730"
67
74
 
68
75
  module Options
76
+ UseBillingForShippingDisabled = "91572"
69
77
  UpdateExistingTokenIsInvalid = "91723"
70
78
  VerificationMerchantAccountIdIsInvalid = "91728"
71
79
  UpdateExistingTokenNotAllowed = "91729"
@@ -101,6 +109,20 @@ module Braintree
101
109
  InternationalPhoneFormatIsInvalid = "92205"
102
110
  end
103
111
 
112
+ module PayPalAccount
113
+ CannotVaultOneTimeUsePayPalAccount = "82902"
114
+ CannotHaveBothAccessTokenAndConsentCode = "82903"
115
+ ConsentCodeOrAccessTokenIsRequired = "82901"
116
+ CustomerIdIsRequiredForVaulting = "82905"
117
+ IncompletePayPalAccount = "82901"
118
+ PaymentMethodNonceConsumed = "92907"
119
+ PaymentMethodNonceLocked = "92909"
120
+ PaymentMethodNonceUnknown = "92908"
121
+ PayPalAccountsAreNotAccepted = "82904"
122
+ PayPalCommunicationError = "92910"
123
+ TokenIsInUse = "92906"
124
+ end
125
+
104
126
  # See http://www.braintreepayments.com/docs/ruby/subscriptions/validations
105
127
  module Subscription
106
128
  BillingDayOfMonthCannotBeUpdated = "91918"
@@ -123,6 +145,10 @@ module Braintree
123
145
  NumberOfBillingCyclesIsTooSmall = "91909"
124
146
  NumberOfBillingCyclesMustBeGreaterThanZero = "91907"
125
147
  NumberOfBillingCyclesMustBeNumeric = "91906"
148
+ PaymentMethodNonceCardTypeIsNotAccepted = "91924"
149
+ PaymentMethodNonceIsInvalid = "91925"
150
+ PaymentMethodNonceNotAssociatedWithCustomer = "91926"
151
+ PaymentMethodNonceUnvaultedCardIsNotAccepted = "91927"
126
152
  PaymentMethodTokenCardTypeIsNotAccepted = "91902"
127
153
  PaymentMethodTokenIsInvalid = "91903"
128
154
  PaymentMethodTokenNotAssociatedWithCustomer = "91905"
@@ -147,6 +173,7 @@ module Braintree
147
173
  ExistingIdIsInvalid = "92011"
148
174
  ExistingIdIsRequired = "92012"
149
175
  IdToRemoveIsIncorrectKind = "92021"
176
+ IdToRemoveIsInvalid = "92025"
150
177
  IdToRemoveIsNotPresent = "92016"
151
178
  InconsistentNumberOfBillingCycles = "92018"
152
179
  InheritedFromIdIsInvalid = "92013"
@@ -173,6 +200,7 @@ module Braintree
173
200
  CannotBeVoided = "91504"
174
201
  CannotCancelRelease = "91562"
175
202
  CannotCloneCredit = "91543"
203
+ CannotCloneTransactionWithPayPalAccount = "91573"
176
204
  CannotCloneTransactionWithVaultCreditCard = "91540"
177
205
  CannotCloneUnsuccessfulTransaction = "91542"
178
206
  CannotCloneVoiceAuthorizations = "91541"
@@ -181,9 +209,12 @@ module Braintree
181
209
  CannotRefundCredit = "91505"
182
210
  CannotRefundUnlessSettled = "91506"
183
211
  CannotRefundWithPendingMerchantAccount = "91559"
212
+ CannotRefundSettlingTransaction = "91574"
184
213
  CannotRefundWithSuspendedMerchantAccount = "91538"
185
214
  CannotReleaseFromEscrow = "91561"
215
+ CannotSimulateTransactionSettlement = "91575"
186
216
  CannotSubmitForSettlement = "91507"
217
+ ChannelIsTooLong = "91550"
187
218
  CreditCardIsRequired = "91508"
188
219
  CustomFieldIsInvalid = "91526"
189
220
  CustomFieldIsTooLong = "81527"
@@ -191,18 +222,23 @@ module Braintree
191
222
  CustomerDoesNotHaveCreditCard = "91511"
192
223
  CustomerIdIsInvalid = "91510"
193
224
  HasAlreadyBeenRefunded = "91512"
194
- MerchantAccountDoesNotSupportRefunds = "91547"
195
225
  MerchantAccountDoesNotSupportMOTO = "91558"
226
+ MerchantAccountDoesNotSupportRefunds = "91547"
196
227
  MerchantAccountIdIsInvalid = "91513"
197
228
  MerchantAccountIsSuspended = "91514"
198
229
  OrderIdIsTooLong = "91501"
199
- ChannelIsTooLong = "91550"
200
230
  PaymentMethodConflict = "91515"
201
231
  PaymentMethodConflictWithVenmoSDK = "91549"
202
232
  PaymentMethodDoesNotBelongToCustomer = "91516"
203
233
  PaymentMethodDoesNotBelongToSubscription = "91527"
234
+ PaymentMethodNonceCardTypeIsNotAccepted = "91567"
235
+ PaymentMethodNonceConsumed = "91564"
236
+ PaymentMethodNonceLocked = "91566"
237
+ PaymentMethodNonceUnknown = "91565"
204
238
  PaymentMethodTokenCardTypeIsNotAccepted = "91517"
205
239
  PaymentMethodTokenIsInvalid = "91518"
240
+ PaymentInstrumentNotSupportedByMerchantAccount = "91577"
241
+ PayPalNotEnabled = "91576"
206
242
  ProcessorAuthorizationCodeCannotBeSet = "91519"
207
243
  ProcessorAuthorizationCodeIsInvalid = "81520"
208
244
  ProcessorDoesNotSupportCredits = "91546"
@@ -213,8 +249,8 @@ module Braintree
213
249
  ServiceFeeAmountCannotBeNegative = "91554"
214
250
  ServiceFeeAmountFormatIsInvalid = "91555"
215
251
  ServiceFeeAmountIsTooLarge = "91556"
216
- ServiceFeeIsNotAllowedOnCredits = "91552"
217
252
  ServiceFeeAmountNotAllowedOnMasterMerchantAccount = "91557"
253
+ ServiceFeeIsNotAllowedOnCredits = "91552"
218
254
  SettlementAmountIsLessThanServiceFeeAmount = "91551"
219
255
  SettlementAmountIsTooLarge = "91522"
220
256
  SubMerchantAccountRequiresServiceFeeAmount = "91553"
@@ -224,6 +260,9 @@ module Braintree
224
260
  TaxAmountCannotBeNegative = "81534"
225
261
  TaxAmountFormatIsInvalid = "81535"
226
262
  TaxAmountIsTooLarge = "81536"
263
+ ThreeDSecureAuthenticationFailed = "81571"
264
+ ThreeDSecureTokenIsInvalid = "91568"
265
+ ThreeDSecureTransactionDataDoesntMatchVerify = "91570"
227
266
  TypeIsInvalid = "91523"
228
267
  TypeIsRequired = "91524"
229
268
  UnsupportedVoiceAuthorization = "91539"
@@ -347,6 +386,34 @@ module Braintree
347
386
  SettlementDateIsInvalid = "82302"
348
387
  CustomFieldIsInvalid = "82303"
349
388
  end
389
+
390
+ module ClientToken
391
+ CustomerDoesNotExist = "92804"
392
+ FailOnDuplicatePaymentMethodRequiresCustomerId = "92803"
393
+ MakeDefaultRequiresCustomerId = "92801"
394
+ ProxyMerchantDoesNotExist = "92805"
395
+ VerifyCardRequiresCustomerId = "92802"
396
+ UnsupportedVersion = "92806"
397
+ end
398
+
399
+ module PaymentMethod
400
+ CustomerIdIsInvalid = "93105"
401
+ CustomerIdIsRequired = "93104"
402
+ NonceIsInvalid = "93102"
403
+ NonceIsRequired = "93103"
404
+ PaymentMethodParamsAreRequired = "93101"
405
+ CannotForwardPaymentMethodType = "93107"
406
+ end
407
+
408
+ module AuthorizationFingerprint
409
+ InvalidCreatedAt = "93204"
410
+ InvalidFormat = "93202"
411
+ InvalidPublicKey = "93205"
412
+ InvalidSignature = "93206"
413
+ MissingFingerprint = "93201"
414
+ OptionsNotAllowedWithoutCustomer = "93207"
415
+ SignatureRevoked = "93203"
416
+ end
350
417
  end
351
418
  end
352
419
 
@@ -55,5 +55,7 @@ module Braintree # :nodoc:
55
55
  inspect
56
56
  end
57
57
  end
58
+
59
+ class TestOperationPerformedInProduction < BraintreeError; end
58
60
  end
59
61
 
@@ -41,10 +41,22 @@ module Braintree
41
41
  PlanGateway.new(self)
42
42
  end
43
43
 
44
+ def payment_method
45
+ PaymentMethodGateway.new(self)
46
+ end
47
+
48
+ def paypal_account
49
+ PayPalAccountGateway.new(self)
50
+ end
51
+
44
52
  def merchant_account
45
53
  MerchantAccountGateway.new(self)
46
54
  end
47
55
 
56
+ def sepa_bank_account
57
+ SEPABankAccountGateway.new(self)
58
+ end
59
+
48
60
  def settlement_batch_summary
49
61
  SettlementBatchSummaryGateway.new(self)
50
62
  end
@@ -61,6 +73,10 @@ module Braintree
61
73
  TransactionGateway.new(self)
62
74
  end
63
75
 
76
+ def testing
77
+ TestingGateway.new(self)
78
+ end
79
+
64
80
  def verification
65
81
  CreditCardVerificationGateway.new(self)
66
82
  end
@@ -0,0 +1,7 @@
1
+ module Braintree
2
+ module PaymentInstrumentType
3
+ PayPalAccount = 'paypal_account'
4
+ SEPABankAccount = 'sepa_bank_account'
5
+ CreditCard = 'credit_card'
6
+ end
7
+ end