lib/braintree/error_codes.rb in braintree-1.0.1 vs lib/braintree/error_codes.rb in braintree-1.1.0

- old
+ new

@@ -1,9 +1,9 @@ module Braintree # The ErrorCodes module provides constants for validation errors. # The constants should be used to check for a specific validation error in a ValidationErrorCollection. - # The error messages returned from the server may change, but the codes will remain the same. + # The error messages returned from the server may change, but the codes will remain the same. module ErrorCodes module Address CannotBeBlank = "81801" CompanyIsTooLong = "81802" CountryNameIsNotAccepted = "91803" @@ -33,11 +33,11 @@ ExpirationDateYearIsInvalid = "81711" ExpirationMonthIsInvalid = "81712" ExpirationYearIsInvalid = "81713" NumberIsRequired = "81714" NumberIsInvalid = "81715" - NumberInvalidLength = "81716" + NumberHasInvalidLength = "81716" NumberMustBeTestNumber = "81717" TokenInvalid = "91718" TokenIsInUse = "91719" TokenIsTooLong = "91720" TokenIsNotAllowed = "91721" @@ -60,20 +60,33 @@ LastNameIsTooLong = "81613" PhoneIsTooLong = "81614" WebsiteIsTooLong = "81615" WebsiteIsInvalid = "81616" end - + + module Subscription + CannotEditCanceledSubscription = "81901" + IdIsInUse = "81902" + PriceCannotBeBlank = "81903" + PriceFormatIsInvalid = "81904" + StatusIsCanceled = "81905" + TokenFormatIsInvalid = "81906" + TrialDurationFormatIsInvalid = "81907" + TrialDurationIsRequired = "81908" + TrialDurationUnitIsInvalid = "81909" + end + module Transaction AmountCannotBeNegative = "81501" AmountIsRequired = "81502" AmountIsInvalid = "81503" CannotBeVoided = "91504" CannotRefundCredit = "91505" CannotRefundUnlessSettled = "91506" CannotSubmitForSettlement = "91507" CreditCardIsRequired = "91508" CustomerDefaultPaymentMethodCardTypeIsNotAccepted = "81509" + CustomFieldIsInvalid = "91526" CustomerIdIsInvalid = "91510" CustomerDoesNotHaveCreditCard = "91511" HasAlreadyBeenRefunded = "91512" MerchantAccountNameIsInvalid = "91513" MerchantAccountIsSuspended = "91514"