swiss-crm-activemerchant 1.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (287) hide show
  1. checksums.yaml +7 -0
  2. data/CHANGELOG +4033 -0
  3. data/CONTRIBUTORS +568 -0
  4. data/MIT-LICENSE +20 -0
  5. data/README.md +252 -0
  6. data/lib/active_merchant/billing/apple_pay_payment_token.rb +22 -0
  7. data/lib/active_merchant/billing/avs_result.rb +95 -0
  8. data/lib/active_merchant/billing/base.rb +48 -0
  9. data/lib/active_merchant/billing/check.rb +112 -0
  10. data/lib/active_merchant/billing/compatibility.rb +118 -0
  11. data/lib/active_merchant/billing/credit_card.rb +451 -0
  12. data/lib/active_merchant/billing/credit_card_formatting.rb +24 -0
  13. data/lib/active_merchant/billing/credit_card_methods.rb +512 -0
  14. data/lib/active_merchant/billing/cvv_result.rb +37 -0
  15. data/lib/active_merchant/billing/gateway.rb +332 -0
  16. data/lib/active_merchant/billing/gateways/adyen.rb +774 -0
  17. data/lib/active_merchant/billing/gateways/airwallex.rb +370 -0
  18. data/lib/active_merchant/billing/gateways/alelo.rb +256 -0
  19. data/lib/active_merchant/billing/gateways/allied_wallet.rb +205 -0
  20. data/lib/active_merchant/billing/gateways/authorize_net.rb +1125 -0
  21. data/lib/active_merchant/billing/gateways/authorize_net_arb.rb +424 -0
  22. data/lib/active_merchant/billing/gateways/authorize_net_cim.rb +977 -0
  23. data/lib/active_merchant/billing/gateways/axcessms.rb +242 -0
  24. data/lib/active_merchant/billing/gateways/balanced.rb +263 -0
  25. data/lib/active_merchant/billing/gateways/bambora_apac.rb +222 -0
  26. data/lib/active_merchant/billing/gateways/bank_frick.rb +225 -0
  27. data/lib/active_merchant/billing/gateways/banwire.rb +116 -0
  28. data/lib/active_merchant/billing/gateways/barclaycard_smartpay.rb +397 -0
  29. data/lib/active_merchant/billing/gateways/barclays_epdq_extra_plus.rb +15 -0
  30. data/lib/active_merchant/billing/gateways/be2bill.rb +131 -0
  31. data/lib/active_merchant/billing/gateways/beanstream/beanstream_core.rb +474 -0
  32. data/lib/active_merchant/billing/gateways/beanstream.rb +238 -0
  33. data/lib/active_merchant/billing/gateways/beanstream_interac.rb +57 -0
  34. data/lib/active_merchant/billing/gateways/blue_pay.rb +549 -0
  35. data/lib/active_merchant/billing/gateways/blue_snap.rb +644 -0
  36. data/lib/active_merchant/billing/gateways/bogus.rb +190 -0
  37. data/lib/active_merchant/billing/gateways/borgun.rb +272 -0
  38. data/lib/active_merchant/billing/gateways/bpoint.rb +277 -0
  39. data/lib/active_merchant/billing/gateways/braintree/braintree_common.rb +28 -0
  40. data/lib/active_merchant/billing/gateways/braintree/token_nonce.rb +113 -0
  41. data/lib/active_merchant/billing/gateways/braintree.rb +19 -0
  42. data/lib/active_merchant/billing/gateways/braintree_blue.rb +952 -0
  43. data/lib/active_merchant/billing/gateways/braintree_orange.rb +19 -0
  44. data/lib/active_merchant/billing/gateways/bridge_pay.rb +244 -0
  45. data/lib/active_merchant/billing/gateways/cams.rb +230 -0
  46. data/lib/active_merchant/billing/gateways/card_connect.rb +338 -0
  47. data/lib/active_merchant/billing/gateways/card_save.rb +21 -0
  48. data/lib/active_merchant/billing/gateways/card_stream.rb +394 -0
  49. data/lib/active_merchant/billing/gateways/cardknox.rb +327 -0
  50. data/lib/active_merchant/billing/gateways/cardprocess.rb +256 -0
  51. data/lib/active_merchant/billing/gateways/cashnet.rb +235 -0
  52. data/lib/active_merchant/billing/gateways/cc5.rb +198 -0
  53. data/lib/active_merchant/billing/gateways/cecabank.rb +249 -0
  54. data/lib/active_merchant/billing/gateways/cenpos.rb +328 -0
  55. data/lib/active_merchant/billing/gateways/checkout.rb +212 -0
  56. data/lib/active_merchant/billing/gateways/checkout_v2.rb +587 -0
  57. data/lib/active_merchant/billing/gateways/citrus_pay.rb +21 -0
  58. data/lib/active_merchant/billing/gateways/clearhaus.rb +219 -0
  59. data/lib/active_merchant/billing/gateways/commerce_hub.rb +366 -0
  60. data/lib/active_merchant/billing/gateways/commercegate.rb +142 -0
  61. data/lib/active_merchant/billing/gateways/conekta.rb +230 -0
  62. data/lib/active_merchant/billing/gateways/creditcall.rb +272 -0
  63. data/lib/active_merchant/billing/gateways/credorax.rb +526 -0
  64. data/lib/active_merchant/billing/gateways/ct_payment.rb +269 -0
  65. data/lib/active_merchant/billing/gateways/culqi.rb +279 -0
  66. data/lib/active_merchant/billing/gateways/cyber_source/cyber_source_common.rb +36 -0
  67. data/lib/active_merchant/billing/gateways/cyber_source.rb +1148 -0
  68. data/lib/active_merchant/billing/gateways/cyber_source_rest.rb +454 -0
  69. data/lib/active_merchant/billing/gateways/d_local.rb +343 -0
  70. data/lib/active_merchant/billing/gateways/data_cash.rb +302 -0
  71. data/lib/active_merchant/billing/gateways/decidir.rb +358 -0
  72. data/lib/active_merchant/billing/gateways/decidir_plus.rb +344 -0
  73. data/lib/active_merchant/billing/gateways/dibs.rb +199 -0
  74. data/lib/active_merchant/billing/gateways/digitzs.rb +295 -0
  75. data/lib/active_merchant/billing/gateways/ebanx.rb +346 -0
  76. data/lib/active_merchant/billing/gateways/efsnet.rb +215 -0
  77. data/lib/active_merchant/billing/gateways/elavon.rb +475 -0
  78. data/lib/active_merchant/billing/gateways/element.rb +406 -0
  79. data/lib/active_merchant/billing/gateways/epay.rb +296 -0
  80. data/lib/active_merchant/billing/gateways/evo_ca.rb +307 -0
  81. data/lib/active_merchant/billing/gateways/eway.rb +226 -0
  82. data/lib/active_merchant/billing/gateways/eway_managed.rb +289 -0
  83. data/lib/active_merchant/billing/gateways/eway_rapid.rb +578 -0
  84. data/lib/active_merchant/billing/gateways/exact.rb +219 -0
  85. data/lib/active_merchant/billing/gateways/ezic.rb +195 -0
  86. data/lib/active_merchant/billing/gateways/fat_zebra.rb +223 -0
  87. data/lib/active_merchant/billing/gateways/federated_canada.rb +158 -0
  88. data/lib/active_merchant/billing/gateways/finansbank.rb +22 -0
  89. data/lib/active_merchant/billing/gateways/first_giving.rb +143 -0
  90. data/lib/active_merchant/billing/gateways/first_pay.rb +182 -0
  91. data/lib/active_merchant/billing/gateways/firstdata_e4.rb +452 -0
  92. data/lib/active_merchant/billing/gateways/firstdata_e4_v27.rb +505 -0
  93. data/lib/active_merchant/billing/gateways/flo2cash.rb +215 -0
  94. data/lib/active_merchant/billing/gateways/flo2cash_simple.rb +20 -0
  95. data/lib/active_merchant/billing/gateways/fluidpay.rb +275 -0
  96. data/lib/active_merchant/billing/gateways/forte.rb +286 -0
  97. data/lib/active_merchant/billing/gateways/garanti.rb +256 -0
  98. data/lib/active_merchant/billing/gateways/global_collect.rb +580 -0
  99. data/lib/active_merchant/billing/gateways/global_transport.rb +193 -0
  100. data/lib/active_merchant/billing/gateways/hdfc.rb +205 -0
  101. data/lib/active_merchant/billing/gateways/hps.rb +472 -0
  102. data/lib/active_merchant/billing/gateways/iats_payments.rb +312 -0
  103. data/lib/active_merchant/billing/gateways/in_context_paypal_express.rb +15 -0
  104. data/lib/active_merchant/billing/gateways/inspire.rb +213 -0
  105. data/lib/active_merchant/billing/gateways/instapay.rb +159 -0
  106. data/lib/active_merchant/billing/gateways/ipg.rb +420 -0
  107. data/lib/active_merchant/billing/gateways/ipp.rb +176 -0
  108. data/lib/active_merchant/billing/gateways/iridium.rb +467 -0
  109. data/lib/active_merchant/billing/gateways/itransact.rb +448 -0
  110. data/lib/active_merchant/billing/gateways/iveri.rb +290 -0
  111. data/lib/active_merchant/billing/gateways/ixopay.rb +320 -0
  112. data/lib/active_merchant/billing/gateways/jetpay.rb +395 -0
  113. data/lib/active_merchant/billing/gateways/jetpay_v2.rb +432 -0
  114. data/lib/active_merchant/billing/gateways/klarna.rb +317 -0
  115. data/lib/active_merchant/billing/gateways/komoju.rb +115 -0
  116. data/lib/active_merchant/billing/gateways/kushki.rb +297 -0
  117. data/lib/active_merchant/billing/gateways/latitude19.rb +412 -0
  118. data/lib/active_merchant/billing/gateways/linkpoint.rb +448 -0
  119. data/lib/active_merchant/billing/gateways/litle.rb +643 -0
  120. data/lib/active_merchant/billing/gateways/mastercard.rb +286 -0
  121. data/lib/active_merchant/billing/gateways/maxipago.rb +220 -0
  122. data/lib/active_merchant/billing/gateways/mercado_pago.rb +348 -0
  123. data/lib/active_merchant/billing/gateways/merchant_e_solutions.rb +228 -0
  124. data/lib/active_merchant/billing/gateways/merchant_one.rb +110 -0
  125. data/lib/active_merchant/billing/gateways/merchant_partners.rb +245 -0
  126. data/lib/active_merchant/billing/gateways/merchant_ware.rb +313 -0
  127. data/lib/active_merchant/billing/gateways/merchant_ware_version_four.rb +284 -0
  128. data/lib/active_merchant/billing/gateways/merchant_warrior.rb +248 -0
  129. data/lib/active_merchant/billing/gateways/mercury.rb +352 -0
  130. data/lib/active_merchant/billing/gateways/metrics_global.rb +293 -0
  131. data/lib/active_merchant/billing/gateways/micropayment.rb +182 -0
  132. data/lib/active_merchant/billing/gateways/migs/migs_codes.rb +100 -0
  133. data/lib/active_merchant/billing/gateways/migs.rb +329 -0
  134. data/lib/active_merchant/billing/gateways/mit.rb +260 -0
  135. data/lib/active_merchant/billing/gateways/modern_payments.rb +37 -0
  136. data/lib/active_merchant/billing/gateways/modern_payments_cim.rb +215 -0
  137. data/lib/active_merchant/billing/gateways/moka.rb +290 -0
  138. data/lib/active_merchant/billing/gateways/monei.rb +424 -0
  139. data/lib/active_merchant/billing/gateways/moneris.rb +488 -0
  140. data/lib/active_merchant/billing/gateways/money_movers.rb +150 -0
  141. data/lib/active_merchant/billing/gateways/mundipagg.rb +366 -0
  142. data/lib/active_merchant/billing/gateways/nab_transact.rb +299 -0
  143. data/lib/active_merchant/billing/gateways/ncr_secure_pay.rb +163 -0
  144. data/lib/active_merchant/billing/gateways/net_registry.rb +198 -0
  145. data/lib/active_merchant/billing/gateways/netaxept.rb +180 -0
  146. data/lib/active_merchant/billing/gateways/netbanx.rb +376 -0
  147. data/lib/active_merchant/billing/gateways/netbilling.rb +229 -0
  148. data/lib/active_merchant/billing/gateways/netpay.rb +223 -0
  149. data/lib/active_merchant/billing/gateways/network_merchants.rb +238 -0
  150. data/lib/active_merchant/billing/gateways/nmi.rb +396 -0
  151. data/lib/active_merchant/billing/gateways/ogone.rb +509 -0
  152. data/lib/active_merchant/billing/gateways/omise.rb +323 -0
  153. data/lib/active_merchant/billing/gateways/openpay.rb +246 -0
  154. data/lib/active_merchant/billing/gateways/opp.rb +394 -0
  155. data/lib/active_merchant/billing/gateways/optimal_payment.rb +331 -0
  156. data/lib/active_merchant/billing/gateways/orbital/orbital_soft_descriptors.rb +45 -0
  157. data/lib/active_merchant/billing/gateways/orbital.rb +1267 -0
  158. data/lib/active_merchant/billing/gateways/pac_net_raven.rb +206 -0
  159. data/lib/active_merchant/billing/gateways/pagarme.rb +239 -0
  160. data/lib/active_merchant/billing/gateways/pago_facil.rb +120 -0
  161. data/lib/active_merchant/billing/gateways/pay_arc.rb +392 -0
  162. data/lib/active_merchant/billing/gateways/pay_conex.rb +245 -0
  163. data/lib/active_merchant/billing/gateways/pay_gate_xml.rb +277 -0
  164. data/lib/active_merchant/billing/gateways/pay_hub.rb +213 -0
  165. data/lib/active_merchant/billing/gateways/pay_junction.rb +390 -0
  166. data/lib/active_merchant/billing/gateways/pay_junction_v2.rb +206 -0
  167. data/lib/active_merchant/billing/gateways/pay_secure.rb +110 -0
  168. data/lib/active_merchant/billing/gateways/pay_trace.rb +450 -0
  169. data/lib/active_merchant/billing/gateways/paybox_direct.rb +224 -0
  170. data/lib/active_merchant/billing/gateways/payeezy.rb +513 -0
  171. data/lib/active_merchant/billing/gateways/payex.rb +409 -0
  172. data/lib/active_merchant/billing/gateways/payflow/payflow_common_api.rb +235 -0
  173. data/lib/active_merchant/billing/gateways/payflow/payflow_express_response.rb +42 -0
  174. data/lib/active_merchant/billing/gateways/payflow/payflow_response.rb +13 -0
  175. data/lib/active_merchant/billing/gateways/payflow.rb +473 -0
  176. data/lib/active_merchant/billing/gateways/payflow_express.rb +220 -0
  177. data/lib/active_merchant/billing/gateways/payflow_express_uk.rb +14 -0
  178. data/lib/active_merchant/billing/gateways/payflow_uk.rb +20 -0
  179. data/lib/active_merchant/billing/gateways/payment_express.rb +373 -0
  180. data/lib/active_merchant/billing/gateways/paymentez.rb +365 -0
  181. data/lib/active_merchant/billing/gateways/paymill.rb +369 -0
  182. data/lib/active_merchant/billing/gateways/paynetworx.rb +228 -0
  183. data/lib/active_merchant/billing/gateways/paypal/paypal_common_api.rb +718 -0
  184. data/lib/active_merchant/billing/gateways/paypal/paypal_express_response.rb +69 -0
  185. data/lib/active_merchant/billing/gateways/paypal/paypal_recurring_api.rb +262 -0
  186. data/lib/active_merchant/billing/gateways/paypal.rb +136 -0
  187. data/lib/active_merchant/billing/gateways/paypal_ca.rb +13 -0
  188. data/lib/active_merchant/billing/gateways/paypal_digital_goods.rb +44 -0
  189. data/lib/active_merchant/billing/gateways/paypal_express.rb +272 -0
  190. data/lib/active_merchant/billing/gateways/paypal_express_common.rb +30 -0
  191. data/lib/active_merchant/billing/gateways/paypal_standard.rb +281 -0
  192. data/lib/active_merchant/billing/gateways/paysafe.rb +420 -0
  193. data/lib/active_merchant/billing/gateways/payscout.rb +159 -0
  194. data/lib/active_merchant/billing/gateways/paystation.rb +204 -0
  195. data/lib/active_merchant/billing/gateways/payu_in.rb +249 -0
  196. data/lib/active_merchant/billing/gateways/payu_latam.rb +482 -0
  197. data/lib/active_merchant/billing/gateways/payway.rb +207 -0
  198. data/lib/active_merchant/billing/gateways/payway_dot_com.rb +253 -0
  199. data/lib/active_merchant/billing/gateways/pin.rb +273 -0
  200. data/lib/active_merchant/billing/gateways/pixxels.rb +263 -0
  201. data/lib/active_merchant/billing/gateways/plexo.rb +308 -0
  202. data/lib/active_merchant/billing/gateways/plugnpay.rb +283 -0
  203. data/lib/active_merchant/billing/gateways/priority.rb +392 -0
  204. data/lib/active_merchant/billing/gateways/pro_pay.rb +325 -0
  205. data/lib/active_merchant/billing/gateways/psigate.rb +227 -0
  206. data/lib/active_merchant/billing/gateways/psl_card.rb +295 -0
  207. data/lib/active_merchant/billing/gateways/qbms.rb +302 -0
  208. data/lib/active_merchant/billing/gateways/quantum.rb +274 -0
  209. data/lib/active_merchant/billing/gateways/quickbooks.rb +377 -0
  210. data/lib/active_merchant/billing/gateways/quickpay/quickpay_common.rb +184 -0
  211. data/lib/active_merchant/billing/gateways/quickpay/quickpay_v10.rb +297 -0
  212. data/lib/active_merchant/billing/gateways/quickpay/quickpay_v4to7.rb +226 -0
  213. data/lib/active_merchant/billing/gateways/quickpay.rb +24 -0
  214. data/lib/active_merchant/billing/gateways/qvalent.rb +305 -0
  215. data/lib/active_merchant/billing/gateways/rapyd.rb +319 -0
  216. data/lib/active_merchant/billing/gateways/reach.rb +277 -0
  217. data/lib/active_merchant/billing/gateways/realex.rb +400 -0
  218. data/lib/active_merchant/billing/gateways/redsys.rb +723 -0
  219. data/lib/active_merchant/billing/gateways/s5.rb +247 -0
  220. data/lib/active_merchant/billing/gateways/safe_charge.rb +298 -0
  221. data/lib/active_merchant/billing/gateways/sage.rb +446 -0
  222. data/lib/active_merchant/billing/gateways/sage_pay.rb +434 -0
  223. data/lib/active_merchant/billing/gateways/sallie_mae.rb +141 -0
  224. data/lib/active_merchant/billing/gateways/secure_net.rb +260 -0
  225. data/lib/active_merchant/billing/gateways/secure_pay.rb +191 -0
  226. data/lib/active_merchant/billing/gateways/secure_pay_au.rb +290 -0
  227. data/lib/active_merchant/billing/gateways/secure_pay_tech.rb +103 -0
  228. data/lib/active_merchant/billing/gateways/securion_pay.rb +305 -0
  229. data/lib/active_merchant/billing/gateways/shift4.rb +345 -0
  230. data/lib/active_merchant/billing/gateways/simetrik.rb +368 -0
  231. data/lib/active_merchant/billing/gateways/skip_jack.rb +450 -0
  232. data/lib/active_merchant/billing/gateways/smart_ps.rb +274 -0
  233. data/lib/active_merchant/billing/gateways/so_easy_pay.rb +194 -0
  234. data/lib/active_merchant/billing/gateways/spreedly_core.rb +354 -0
  235. data/lib/active_merchant/billing/gateways/stripe.rb +866 -0
  236. data/lib/active_merchant/billing/gateways/stripe_payment_intents.rb +602 -0
  237. data/lib/active_merchant/billing/gateways/swipe_checkout.rb +151 -0
  238. data/lib/active_merchant/billing/gateways/telr.rb +273 -0
  239. data/lib/active_merchant/billing/gateways/tns.rb +23 -0
  240. data/lib/active_merchant/billing/gateways/trans_first.rb +240 -0
  241. data/lib/active_merchant/billing/gateways/trans_first_transaction_express.rb +612 -0
  242. data/lib/active_merchant/billing/gateways/transact_pro.rb +222 -0
  243. data/lib/active_merchant/billing/gateways/transax.rb +21 -0
  244. data/lib/active_merchant/billing/gateways/transnational.rb +9 -0
  245. data/lib/active_merchant/billing/gateways/trexle.rb +221 -0
  246. data/lib/active_merchant/billing/gateways/trust_commerce.rb +500 -0
  247. data/lib/active_merchant/billing/gateways/usa_epay.rb +24 -0
  248. data/lib/active_merchant/billing/gateways/usa_epay_advanced.rb +1612 -0
  249. data/lib/active_merchant/billing/gateways/usa_epay_transaction.rb +367 -0
  250. data/lib/active_merchant/billing/gateways/vanco.rb +303 -0
  251. data/lib/active_merchant/billing/gateways/verifi.rb +224 -0
  252. data/lib/active_merchant/billing/gateways/viaklix.rb +171 -0
  253. data/lib/active_merchant/billing/gateways/visanet_peru.rb +250 -0
  254. data/lib/active_merchant/billing/gateways/vpos.rb +223 -0
  255. data/lib/active_merchant/billing/gateways/webpay.rb +97 -0
  256. data/lib/active_merchant/billing/gateways/wepay.rb +235 -0
  257. data/lib/active_merchant/billing/gateways/wirecard.rb +430 -0
  258. data/lib/active_merchant/billing/gateways/wompi.rb +197 -0
  259. data/lib/active_merchant/billing/gateways/world_net.rb +345 -0
  260. data/lib/active_merchant/billing/gateways/worldpay.rb +1050 -0
  261. data/lib/active_merchant/billing/gateways/worldpay_online_payments.rb +208 -0
  262. data/lib/active_merchant/billing/gateways/worldpay_us.rb +221 -0
  263. data/lib/active_merchant/billing/gateways.rb +14 -0
  264. data/lib/active_merchant/billing/model.rb +30 -0
  265. data/lib/active_merchant/billing/network_tokenization_credit_card.rb +39 -0
  266. data/lib/active_merchant/billing/payment_token.rb +21 -0
  267. data/lib/active_merchant/billing/rails.rb +3 -0
  268. data/lib/active_merchant/billing/response.rb +121 -0
  269. data/lib/active_merchant/billing/three_d_secure_eci_mapper.rb +27 -0
  270. data/lib/active_merchant/billing.rb +16 -0
  271. data/lib/active_merchant/connection.rb +194 -0
  272. data/lib/active_merchant/country.rb +338 -0
  273. data/lib/active_merchant/empty.rb +20 -0
  274. data/lib/active_merchant/errors.rb +38 -0
  275. data/lib/active_merchant/net_http_ssl_connection.rb +11 -0
  276. data/lib/active_merchant/network_connection_retries.rb +78 -0
  277. data/lib/active_merchant/post_data.rb +26 -0
  278. data/lib/active_merchant/posts_data.rb +92 -0
  279. data/lib/active_merchant/version.rb +3 -0
  280. data/lib/active_merchant.rb +63 -0
  281. data/lib/activemerchant.rb +1 -0
  282. data/lib/certs/cacert.pem +3214 -0
  283. data/lib/support/gateway_support.rb +69 -0
  284. data/lib/support/outbound_hosts.rb +28 -0
  285. data/lib/support/ssl_verify.rb +88 -0
  286. data/lib/support/ssl_version.rb +86 -0
  287. metadata +506 -0
@@ -0,0 +1,578 @@
1
+ require 'json'
2
+
3
+ module ActiveMerchant #:nodoc:
4
+ module Billing #:nodoc:
5
+ class EwayRapidGateway < Gateway
6
+ self.test_url = 'https://api.sandbox.ewaypayments.com/'
7
+ self.live_url = 'https://api.ewaypayments.com/'
8
+
9
+ self.money_format = :cents
10
+ self.supported_countries = %w[AU NZ GB SG MY HK]
11
+ self.supported_cardtypes = %i[visa master american_express diners_club jcb]
12
+ self.homepage_url = 'http://www.eway.com.au/'
13
+ self.display_name = 'eWAY Rapid 3.1'
14
+ self.default_currency = 'AUD'
15
+
16
+ class_attribute :partner_id
17
+
18
+ def initialize(options = {})
19
+ requires!(options, :login, :password)
20
+ super
21
+ end
22
+
23
+ # Public: Run a purchase transaction.
24
+ #
25
+ # amount - The monetary amount of the transaction in cents.
26
+ # payment_method - The payment method or authorization token returned from store.
27
+ # options - A standard ActiveMerchant options hash:
28
+ # :transaction_type - One of: Purchase (default), MOTO
29
+ # or Recurring. For stored card payments (aka - TokenPayments),
30
+ # this must be either MOTO or Recurring.
31
+ # :invoice - The merchant’s invoice number for this
32
+ # transaction (optional).
33
+ # :order_id - A merchant-supplied identifier for the
34
+ # transaction (optional).
35
+ # :description - A merchant-supplied description of the
36
+ # transaction (optional).
37
+ # :currency - Three letter currency code for the
38
+ # transaction (default: "AUD")
39
+ # :billing_address - Standard ActiveMerchant address hash
40
+ # (optional).
41
+ # :shipping_address - Standard ActiveMerchant address hash
42
+ # (optional).
43
+ # :ip - The ip of the consumer initiating the
44
+ # transaction (optional).
45
+ # :application_id - A string identifying the application
46
+ # submitting the transaction
47
+ # (default: "https://github.com/activemerchant/active_merchant")
48
+ #
49
+ # Returns an ActiveMerchant::Billing::Response object where authorization is the Transaction ID on success
50
+ def purchase(amount, payment_method, options = {})
51
+ params = {}
52
+ add_metadata(params, options)
53
+ add_invoice(params, amount, options)
54
+ add_customer_data(params, options, payment_method)
55
+ add_credit_card(params, payment_method, options)
56
+ add_3ds_authenticated_data(params, options) if options[:three_d_secure]
57
+ params['Method'] = payment_method.respond_to?(:number) ? 'ProcessPayment' : 'TokenPayment'
58
+ commit(url_for('Transaction'), params)
59
+ end
60
+
61
+ def authorize(amount, payment_method, options = {})
62
+ params = {}
63
+ add_metadata(params, options)
64
+ add_invoice(params, amount, options)
65
+ add_customer_data(params, options, payment_method)
66
+ add_credit_card(params, payment_method, options)
67
+ params['Method'] = 'Authorise'
68
+ commit(url_for('Authorisation'), params)
69
+ end
70
+
71
+ def capture(amount, identification, options = {})
72
+ params = {}
73
+ add_metadata(params, options)
74
+ add_invoice(params, amount, options)
75
+ add_reference(params, identification)
76
+ commit(url_for('CapturePayment'), params)
77
+ end
78
+
79
+ def void(identification, options = {})
80
+ params = {}
81
+ add_reference(params, identification)
82
+ commit(url_for('CancelAuthorisation'), params)
83
+ end
84
+
85
+ # Public: Refund a transaction.
86
+ #
87
+ # amount - The monetary amount of the transaction in cents
88
+ # identification - The transaction id which is returned in the
89
+ # authorization of the successful purchase transaction
90
+ # options - A standard ActiveMerchant options hash:
91
+ # :invoice - The merchant’s invoice number for this
92
+ # transaction (optional).
93
+ # :order_id - A merchant-supplied identifier for the
94
+ # transaction (optional).
95
+ # :description - A merchant-supplied description of the
96
+ # transaction (optional).
97
+ # :currency - Three letter currency code for the
98
+ # transaction (default: "AUD")
99
+ # :billing_address - Standard ActiveMerchant address hash
100
+ # (optional).
101
+ # :shipping_address - Standard ActiveMerchant address hash
102
+ # (optional).
103
+ # :ip - The ip of the consumer initiating the
104
+ # transaction (optional).
105
+ # :application_id - A string identifying the application
106
+ # submitting the transaction
107
+ # (default: "https://github.com/activemerchant/active_merchant")
108
+ #
109
+ # Returns an ActiveMerchant::Billing::Response object
110
+ def refund(amount, identification, options = {})
111
+ params = {}
112
+ add_metadata(params, options)
113
+ add_invoice(params, amount, options, 'Refund')
114
+ add_reference(params['Refund'], identification)
115
+ add_customer_data(params, options)
116
+ commit(url_for("Transaction/#{identification}/Refund"), params)
117
+ end
118
+
119
+ # Public: Store card details and return a valid token
120
+ #
121
+ # payment_method - The payment method or nil if :customer_token is provided
122
+ # options - A supplemented ActiveMerchant options hash:
123
+ # :order_id - A merchant-supplied identifier for the
124
+ # transaction (optional).
125
+ # :description - A merchant-supplied description of the
126
+ # transaction (optional).
127
+ # :billing_address - Standard ActiveMerchant address hash
128
+ # (required).
129
+ # :ip - The ip of the consumer initiating the
130
+ # transaction (optional).
131
+ # :application_id - A string identifying the application
132
+ # submitting the transaction
133
+ # (default: "https://github.com/activemerchant/active_merchant")
134
+ #
135
+ # Returns an ActiveMerchant::Billing::Response object where the authorization is the customer_token on success
136
+ def store(payment_method, options = {})
137
+ requires!(options, :billing_address)
138
+ params = {}
139
+ add_metadata(params, options)
140
+ add_invoice(params, 0, options)
141
+ add_customer_data(params, options, payment_method)
142
+ add_credit_card(params, payment_method, options)
143
+ params['Method'] = 'CreateTokenCustomer'
144
+ commit(url_for('Transaction'), params)
145
+ end
146
+
147
+ # Public: Update a customer's data
148
+ #
149
+ # customer_token - The customer token returned in the authorization of
150
+ # a successful store transaction.
151
+ # payment_method - The payment method or nil if :customer_token is provided
152
+ # options - A supplemented ActiveMerchant options hash:
153
+ # :order_id - A merchant-supplied identifier for the
154
+ # transaction (optional).
155
+ # :description - A merchant-supplied description of the
156
+ # transaction (optional).
157
+ # :billing_address - Standard ActiveMerchant address hash
158
+ # (optional).
159
+ # :ip - The ip of the consumer initiating the
160
+ # transaction (optional).
161
+ # :application_id - A string identifying the application
162
+ # submitting the transaction
163
+ # (default: "https://github.com/activemerchant/active_merchant")
164
+ #
165
+ # Returns an ActiveMerchant::Billing::Response object where the authorization is the customer_token on success
166
+ def update(customer_token, payment_method, options = {})
167
+ params = {}
168
+ add_metadata(params, options)
169
+ add_invoice(params, 0, options)
170
+ add_customer_data(params, options, payment_method)
171
+ add_credit_card(params, payment_method, options)
172
+ add_customer_token(params, customer_token)
173
+ params['Method'] = 'UpdateTokenCustomer'
174
+ commit(url_for('Transaction'), params)
175
+ end
176
+
177
+ def supports_scrubbing
178
+ true
179
+ end
180
+
181
+ def scrub(transcript)
182
+ transcript.
183
+ gsub(%r((Authorization: Basic )\w+), '\1[FILTERED]').
184
+ gsub(%r(("Number\\?":\\?")[^"]*)i, '\1[FILTERED]').
185
+ gsub(%r(("CVN\\?":\\?"?)[^",]*)i, '\1[FILTERED]')
186
+ end
187
+
188
+ private
189
+
190
+ def add_metadata(params, options)
191
+ params['RedirectUrl'] = options[:redirect_url] || 'http://example.com'
192
+ params['CustomerIP'] = options[:ip] if options[:ip]
193
+ params['TransactionType'] = options[:transaction_type] || 'Purchase'
194
+ params['DeviceID'] = options[:application_id] || application_id
195
+ if partner = options[:partner_id] || partner_id
196
+ params['PartnerID'] = truncate(partner, 50)
197
+ end
198
+ params
199
+ end
200
+
201
+ def add_3ds_authenticated_data(params, options)
202
+ three_d_secure_options = options[:three_d_secure]
203
+ params['PaymentInstrument'] ||= {} if params['PaymentInstrument'].nil?
204
+ threed_secure_auth = params['PaymentInstrument']['ThreeDSecureAuth'] = {}
205
+ threed_secure_auth['Cryptogram'] = three_d_secure_options[:cavv]
206
+ threed_secure_auth['ECI'] = three_d_secure_options[:eci]
207
+ threed_secure_auth['XID'] = three_d_secure_options[:xid]
208
+ threed_secure_auth['AuthStatus'] = three_d_secure_options[:authentication_response_status]
209
+ threed_secure_auth['dsTransactionId'] = three_d_secure_options[:ds_transaction_id]
210
+ threed_secure_auth['Version'] = three_d_secure_options[:version]
211
+ end
212
+
213
+ def add_invoice(params, money, options, key = 'Payment')
214
+ currency_code = options[:currency] || currency(money)
215
+ params[key] = {
216
+ 'TotalAmount' => localized_amount(money, currency_code),
217
+ 'InvoiceReference' => truncate(options[:order_id], 50),
218
+ 'InvoiceNumber' => truncate(options[:invoice] || options[:order_id], 12),
219
+ 'InvoiceDescription' => truncate(options[:description], 64),
220
+ 'CurrencyCode' => currency_code
221
+ }
222
+ end
223
+
224
+ def add_reference(params, reference)
225
+ params['TransactionID'] = reference
226
+ end
227
+
228
+ def add_customer_data(params, options, payment_method = nil)
229
+ add_customer_fields(params, options, payment_method)
230
+ add_shipping_fields(params, options)
231
+ end
232
+
233
+ def add_customer_fields(params, options, payment_method)
234
+ key = 'Customer'
235
+ params[key] ||= {}
236
+
237
+ customer_address = options[:billing_address] || options[:address]
238
+
239
+ add_name_and_email(params[key], customer_address, options[:email], payment_method)
240
+ add_address(params[key], customer_address)
241
+ end
242
+
243
+ def add_shipping_fields(params, options)
244
+ key = 'ShippingAddress'
245
+ params[key] = {}
246
+
247
+ add_name_and_email(params[key], options[:shipping_address], options[:email])
248
+ add_address(params[key], options[:shipping_address], { skip_company: true })
249
+ end
250
+
251
+ def add_name_and_email(params, address, email, payment_method = nil)
252
+ if address.present?
253
+ params['FirstName'], params['LastName'] = split_names(address[:name])
254
+ elsif payment_method_name_available?(payment_method)
255
+ params['FirstName'] = payment_method.first_name
256
+ params['LastName'] = payment_method.last_name
257
+ end
258
+
259
+ params['Email'] = email
260
+ end
261
+
262
+ def payment_method_name_available?(payment_method)
263
+ payment_method.respond_to?(:first_name) && payment_method.respond_to?(:last_name) &&
264
+ payment_method.first_name.present? && payment_method.last_name.present?
265
+ end
266
+
267
+ def add_address(params, address, options = {})
268
+ return unless address
269
+
270
+ params['Title'] = address[:title]
271
+ params['CompanyName'] = address[:company] unless options[:skip_company]
272
+ params['Street1'] = truncate(address[:address1], 50)
273
+ params['Street2'] = truncate(address[:address2], 50)
274
+ params['City'] = truncate(address[:city], 50)
275
+ params['State'] = address[:state]
276
+ params['PostalCode'] = address[:zip]
277
+ params['Country'] = address[:country].to_s.downcase
278
+ params['Phone'] = address[:phone] || address[:phone_number]
279
+ params['Fax'] = address[:fax]
280
+ end
281
+
282
+ def add_credit_card(params, credit_card, options)
283
+ return unless credit_card
284
+
285
+ params['Customer'] ||= {}
286
+ if credit_card.respond_to? :number
287
+ card_details = params['Customer']['CardDetails'] = {}
288
+ card_details['Name'] = truncate(credit_card.name, 50)
289
+ card_details['Number'] = credit_card.number
290
+ card_details['ExpiryMonth'] = '%02d' % (credit_card.month || 0)
291
+ card_details['ExpiryYear'] = '%02d' % (credit_card.year || 0)
292
+ card_details['CVN'] = credit_card.verification_value
293
+ else
294
+ add_customer_token(params, credit_card)
295
+ end
296
+ end
297
+
298
+ def add_customer_token(params, token)
299
+ params['Customer'] ||= {}
300
+ params['Customer']['TokenCustomerID'] = token
301
+ end
302
+
303
+ def url_for(action)
304
+ (test? ? test_url : live_url) + action
305
+ end
306
+
307
+ def commit(url, params)
308
+ headers = {
309
+ 'Authorization' => ('Basic ' + Base64.strict_encode64(@options[:login].to_s + ':' + @options[:password].to_s).chomp),
310
+ 'Content-Type' => 'application/json'
311
+ }
312
+ request = params.to_json
313
+ raw = parse(ssl_post(url, request, headers))
314
+
315
+ succeeded = success?(raw)
316
+ ActiveMerchant::Billing::Response.new(
317
+ succeeded,
318
+ message_from(succeeded, raw),
319
+ raw,
320
+ authorization: authorization_from(raw),
321
+ test: test?,
322
+ avs_result: avs_result_from(raw),
323
+ cvv_result: cvv_result_from(raw)
324
+ )
325
+ rescue ActiveMerchant::ResponseError => e
326
+ return ActiveMerchant::Billing::Response.new(false, e.response.message, { status_code: e.response.code }, test: test?)
327
+ end
328
+
329
+ def parse(data)
330
+ JSON.parse(data)
331
+ end
332
+
333
+ def success?(response)
334
+ if response['ResponseCode'] == '00'
335
+ true
336
+ elsif response['TransactionStatus']
337
+ (response['TransactionStatus'] == true)
338
+ elsif response['Succeeded']
339
+ (response['Succeeded'] == true)
340
+ else
341
+ false
342
+ end
343
+ end
344
+
345
+ def parse_errors(message)
346
+ errors = message.split(',').collect { |code| MESSAGES[code.strip] }.flatten.join(',')
347
+ errors.presence || message
348
+ end
349
+
350
+ def message_from(succeeded, response)
351
+ if response['Errors']
352
+ parse_errors(response['Errors'])
353
+ elsif response['ResponseMessage']
354
+ parse_errors(response['ResponseMessage'])
355
+ elsif response['ResponseCode']
356
+ ActiveMerchant::Billing::EwayGateway::MESSAGES[response['ResponseCode']]
357
+ elsif succeeded
358
+ 'Succeeded'
359
+ else
360
+ 'Failed'
361
+ end
362
+ end
363
+
364
+ def authorization_from(response)
365
+ # Note: TransactionID is always null for store requests, but TokenCustomerID is also sent back for purchase from
366
+ # stored card transactions so we give precedence to TransactionID
367
+ response['TransactionID'] || response['Customer']['TokenCustomerID']
368
+ end
369
+
370
+ def avs_result_from(response)
371
+ verification = response['Verification'] || {}
372
+ code =
373
+ case verification['Address']
374
+ when 'Valid'
375
+ 'M'
376
+ when 'Invalid'
377
+ 'N'
378
+ else
379
+ 'I'
380
+ end
381
+ { code: code }
382
+ end
383
+
384
+ def cvv_result_from(response)
385
+ verification = response['Verification'] || {}
386
+ case verification['CVN']
387
+ when 'Valid'
388
+ 'M'
389
+ when 'Invalid'
390
+ 'N'
391
+ else
392
+ 'P'
393
+ end
394
+ end
395
+
396
+ MESSAGES = {
397
+ 'A2000' => 'Transaction Approved Successful',
398
+ 'A2008' => 'Honour With Identification Successful',
399
+ 'A2010' => 'Approved For Partial Amount Successful',
400
+ 'A2011' => 'Approved, VIP Successful',
401
+ 'A2016' => 'Approved, Update Track 3 Successful',
402
+ 'D4401' => 'Refer to Issuer Failed',
403
+ 'D4402' => 'Refer to Issuer, special Failed',
404
+ 'D4403' => 'No Merchant Failed',
405
+ 'D4404' => 'Pick Up Card Failed',
406
+ 'D4405' => 'Do Not Honour Failed',
407
+ 'D4406' => 'Error Failed',
408
+ 'D4407' => 'Pick Up Card, Special Failed',
409
+ 'D4409' => 'Request In Progress Failed',
410
+ 'D4412' => 'Invalid Transaction Failed',
411
+ 'D4413' => 'Invalid Amount Failed',
412
+ 'D4414' => 'Invalid Card Number Failed',
413
+ 'D4415' => 'No Issuer Failed',
414
+ 'D4419' => 'Re-enter Last Transaction Failed',
415
+ 'D4421' => 'No Action Taken Failed',
416
+ 'D4422' => 'Suspected Malfunction Failed',
417
+ 'D4423' => 'Unacceptable Transaction Fee Failed',
418
+ 'D4425' => 'Unable to Locate Record On File Failed',
419
+ 'D4430' => 'Format Error Failed ',
420
+ 'D4431' => 'Bank Not Supported By Switch Failed',
421
+ 'D4433' => 'Expired Card, Capture Failed ',
422
+ 'D4434' => 'Suspected Fraud, Retain Card Failed',
423
+ 'D4435' => 'Card Acceptor, Contact Acquirer, Retain Card Failed',
424
+ 'D4436' => 'Restricted Card, Retain Card Failed',
425
+ 'D4437' => 'Contact Acquirer Security Department, Retain Card Failed',
426
+ 'D4438' => 'PIN Tries Exceeded, Capture Failed',
427
+ 'D4439' => 'No Credit Account Failed',
428
+ 'D4440' => 'Function Not Supported Failed',
429
+ 'D4441' => 'Lost Card Failed',
430
+ 'D4442' => 'No Universal Account Failed',
431
+ 'D4443' => 'Stolen Card Failed',
432
+ 'D4444' => 'No Investment Account Failed',
433
+ 'D4451' => 'Insufficient Funds Failed',
434
+ 'D4452' => 'No Cheque Account Failed',
435
+ 'D4453' => 'No Savings Account Failed',
436
+ 'D4454' => 'Expired Card Failed',
437
+ 'D4455' => 'Incorrect PIN Failed',
438
+ 'D4456' => 'No Card Record Failed',
439
+ 'D4457' => 'Function Not Permitted to Cardholder Failed',
440
+ 'D4458' => 'Function Not Permitted to Terminal Failed',
441
+ 'D4459' => 'Suspected Fraud Failed',
442
+ 'D4460' => 'Acceptor Contact Acquirer Failed',
443
+ 'D4461' => 'Exceeds Withdrawal Limit Failed',
444
+ 'D4462' => 'Restricted Card Failed',
445
+ 'D4463' => 'Security Violation Failed',
446
+ 'D4464' => 'Original Amount Incorrect Failed',
447
+ 'D4466' => 'Acceptor Contact Acquirer, Security Failed',
448
+ 'D4467' => 'Capture Card Failed',
449
+ 'D4475' => 'PIN Tries Exceeded Failed',
450
+ 'D4482' => 'CVV Validation Error Failed',
451
+ 'D4490' => 'Cut off In Progress Failed',
452
+ 'D4491' => 'Card Issuer Unavailable Failed',
453
+ 'D4492' => 'Unable To Route Transaction Failed',
454
+ 'D4493' => 'Cannot Complete, Violation Of The Law Failed',
455
+ 'D4494' => 'Duplicate Transaction Failed',
456
+ 'D4496' => 'System Error Failed',
457
+ 'D4497' => 'MasterPass Error Failed',
458
+ 'D4498' => 'PayPal Create Transaction Error Failed',
459
+ 'D4499' => 'Invalid Transaction for Auth/Void Failed',
460
+ 'S5000' => 'System Error',
461
+ 'S5011' => 'PayPal Connection Error',
462
+ 'S5012' => 'PayPal Settings Error',
463
+ 'S5085' => 'Started 3dSecure',
464
+ 'S5086' => 'Routed 3dSecure',
465
+ 'S5087' => 'Completed 3dSecure',
466
+ 'S5088' => 'PayPal Transaction Created',
467
+ 'S5099' => 'Incomplete (Access Code in progress/incomplete)',
468
+ 'S5010' => 'Unknown error returned by gateway',
469
+ 'V6000' => 'Validation error',
470
+ 'V6001' => 'Invalid CustomerIP',
471
+ 'V6002' => 'Invalid DeviceID',
472
+ 'V6003' => 'Invalid Request PartnerID',
473
+ 'V6004' => 'Invalid Request Method',
474
+ 'V6010' => 'Invalid TransactionType, account not certified for eCome only MOTO or Recurring available',
475
+ 'V6011' => 'Invalid Payment TotalAmount',
476
+ 'V6012' => 'Invalid Payment InvoiceDescription',
477
+ 'V6013' => 'Invalid Payment InvoiceNumber',
478
+ 'V6014' => 'Invalid Payment InvoiceReference',
479
+ 'V6015' => 'Invalid Payment CurrencyCode',
480
+ 'V6016' => 'Payment Required',
481
+ 'V6017' => 'Payment CurrencyCode Required',
482
+ 'V6018' => 'Unknown Payment CurrencyCode',
483
+ 'V6021' => 'EWAY_CARDHOLDERNAME Required',
484
+ 'V6022' => 'EWAY_CARDNUMBER Required',
485
+ 'V6023' => 'EWAY_CARDCVN Required',
486
+ 'V6033' => 'Invalid Expiry Date',
487
+ 'V6034' => 'Invalid Issue Number',
488
+ 'V6035' => 'Invalid Valid From Date',
489
+ 'V6040' => 'Invalid TokenCustomerID',
490
+ 'V6041' => 'Customer Required',
491
+ 'V6042' => 'Customer FirstName Required',
492
+ 'V6043' => 'Customer LastName Required',
493
+ 'V6044' => 'Customer CountryCode Required',
494
+ 'V6045' => 'Customer Title Required ',
495
+ 'V6046' => 'TokenCustomerID Required',
496
+ 'V6047' => 'RedirectURL Required',
497
+ 'V6048' => 'Invalid Checkout URL',
498
+ 'V6051' => 'Invalid Customer FirstName',
499
+ 'V6052' => 'Invalid Customer LastName',
500
+ 'V6053' => 'Invalid Customer CountryCode',
501
+ 'V6058' => 'Invalid Customer Title ',
502
+ 'V6059' => 'Invalid RedirectURL',
503
+ 'V6060' => 'Invalid TokenCustomerID',
504
+ 'V6061' => 'Invalid Customer Reference',
505
+ 'V6062' => 'Invalid Customer CompanyName',
506
+ 'V6063' => 'Invalid Customer JobDescription',
507
+ 'V6064' => 'Invalid Customer Street1',
508
+ 'V6065' => 'Invalid Customer Street2',
509
+ 'V6066' => 'Invalid Customer City',
510
+ 'V6067' => 'Invalid Customer State',
511
+ 'V6068' => 'Invalid Customer PostalCode',
512
+ 'V6069' => 'Invalid Customer Email ',
513
+ 'V6070' => 'Invalid Customer Phone',
514
+ 'V6071' => 'Invalid Customer Mobile',
515
+ 'V6072' => 'Invalid Customer Comments',
516
+ 'V6073' => 'Invalid Customer Fax',
517
+ 'V6074' => 'Invalid Customer URL',
518
+ 'V6075' => 'Invalid ShippingAddress FirstName',
519
+ 'V6076' => 'Invalid ShippingAddress LastName',
520
+ 'V6077' => 'Invalid ShippingAddress Street1',
521
+ 'V6078' => 'Invalid ShippingAddress Street2',
522
+ 'V6079' => 'Invalid ShippingAddress City',
523
+ 'V6080' => 'Invalid ShippingAddress State',
524
+ 'V6081' => 'Invalid ShippingAddress PostalCode',
525
+ 'V6082' => 'Invalid ShippingAddress Email',
526
+ 'V6083' => 'Invalid ShippingAddress Phone',
527
+ 'V6084' => 'Invalid ShippingAddress Country',
528
+ 'V6085' => 'Invalid ShippingAddress ShippingMethod',
529
+ 'V6086' => 'Invalid ShippingAddress Fax',
530
+ 'V6091' => 'Unknown Customer CountryCode',
531
+ 'V6092' => 'Unknown ShippingAddress CountryCode',
532
+ 'V6100' => 'Invalid EWAY_CARDNAME',
533
+ 'V6101' => 'Invalid EWAY_CARDEXPIRYMONTH',
534
+ 'V6102' => 'Invalid EWAY_CARDEXPIRYYEAR ',
535
+ 'V6103' => 'Invalid EWAY_CARDSTARTMONTH',
536
+ 'V6104' => 'Invalid EWAY_CARDSTARTYEAR',
537
+ 'V6105' => 'Invalid EWAY_CARDISSUENUMBER ',
538
+ 'V6106' => 'Invalid EWAY_CARDCVN',
539
+ 'V6107' => 'Invalid EWAY_ACCESSCODE',
540
+ 'V6108' => 'Invalid CustomerHostAddress',
541
+ 'V6109' => 'Invalid UserAgent',
542
+ 'V6110' => 'Invalid EWAY_CARDNUMBER',
543
+ 'V6111' => 'Unauthorised API Access, Account Not PCI Certified',
544
+ 'V6112' => 'Redundant card details other than expiry year and month',
545
+ 'V6113' => 'Invalid transaction for refund',
546
+ 'V6114' => 'Gateway validation error',
547
+ 'V6115' => 'Invalid DirectRefundRequest, Transaction ID',
548
+ 'V6116' => 'Invalid card data on original TransactionID',
549
+ 'V6117' => 'Invalid CreateAccessCodeSharedRequest, FooterText',
550
+ 'V6118' => 'Invalid CreateAccessCodeSharedRequest, HeaderText',
551
+ 'V6119' => 'Invalid CreateAccessCodeSharedRequest, Language',
552
+ 'V6120' => 'Invalid CreateAccessCodeSharedRequest, LogoUrl ',
553
+ 'V6121' => 'Invalid TransactionSearch, Filter Match Type',
554
+ 'V6122' => 'Invalid TransactionSearch, Non numeric Transaction ID',
555
+ 'V6123' => 'Invalid TransactionSearch,no TransactionID or AccessCode specified',
556
+ 'V6124' => 'Invalid Line Items. The line items have been provided however the totals do not match the TotalAmount field',
557
+ 'V6125' => 'Selected Payment Type not enabled',
558
+ 'V6126' => 'Invalid encrypted card number, decryption failed',
559
+ 'V6127' => 'Invalid encrypted cvn, decryption failed',
560
+ 'V6128' => 'Invalid Method for Payment Type',
561
+ 'V6129' => 'Transaction has not been authorised for Capture/Cancellation',
562
+ 'V6130' => 'Generic customer information error ',
563
+ 'V6131' => 'Generic shipping information error',
564
+ 'V6132' => 'Transaction has already been completed or voided, operation not permitted',
565
+ 'V6133' => 'Checkout not available for Payment Type',
566
+ 'V6134' => 'Invalid Auth Transaction ID for Capture/Void',
567
+ 'V6135' => 'PayPal Error Processing Refund',
568
+ 'V6140' => 'Merchant account is suspended',
569
+ 'V6141' => 'Invalid PayPal account details or API signature',
570
+ 'V6142' => 'Authorise not available for Bank/Branch',
571
+ 'V6150' => 'Invalid Refund Amount',
572
+ 'V6151' => 'Refund amount greater than original transaction',
573
+ 'V6152' => 'Original transaction already refunded for total amount',
574
+ 'V6153' => 'Card type not support by merchant'
575
+ }
576
+ end
577
+ end
578
+ end