lolita-first-data 1.0.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/{LICENSE.txt → MIT-LICENSE} +1 -1
- data/README.md +8 -89
- data/Rakefile +22 -45
- data/app/controllers/lolita_first_data/application_controller.rb +23 -0
- data/app/controllers/lolita_first_data/test_controller.rb +73 -0
- data/app/controllers/lolita_first_data/transactions_controller.rb +63 -0
- data/app/models/lolita_first_data/transaction.rb +45 -0
- data/config/locales/en.yml +109 -109
- data/config/locales/lv.yml +109 -109
- data/config/routes.rb +5 -5
- data/lib/generators/lolita_first_data/install_generator.rb +13 -14
- data/lib/generators/lolita_first_data/templates/migration.rb +21 -21
- data/lib/lolita-first-data.rb +25 -6
- data/lib/lolita_first_data/billing.rb +82 -0
- data/lib/lolita_first_data/custom_logger.rb +8 -0
- data/lib/lolita_first_data/engine.rb +5 -0
- data/lib/lolita_first_data/version.rb +3 -0
- data/lib/tasks/lolita_first_data_tasks.rake +4 -0
- metadata +100 -102
- data/.rspec +0 -2
- data/Gemfile +0 -15
- data/Gemfile.lock +0 -140
- data/VERSION +0 -1
- data/app/controllers/lolita/first_data/common_controller.rb +0 -25
- data/app/controllers/lolita/first_data/test_controller.rb +0 -78
- data/app/controllers/lolita/first_data/transaction_controller.rb +0 -49
- data/app/models/lolita/first_data/transaction.rb +0 -55
- data/lib/lolita-first-data/billing.rb +0 -37
- data/lib/lolita-first-data/custom_logger.rb +0 -10
- data/lib/lolita-first-data/gateway.rb +0 -160
- data/lib/lolita-first-data/rails.rb +0 -6
- data/lib/tasks/first_data_tasks.rake +0 -78
- data/lolita-first-data.gemspec +0 -95
- data/spec/cert.pem +0 -63
- data/spec/fabricators/reservation_fabricator.rb +0 -4
- data/spec/fabricators/transaction_fabricator.rb +0 -7
- data/spec/first_data_spec.rb +0 -67
- data/spec/spec_helper.rb +0 -101
- data/spec/support/rails.rb +0 -16
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: c5b18e527d4f1de23a385525fcf06fb7cf13069b
|
4
|
+
data.tar.gz: 928b4fa41df65bfd323e2048c0197fd3097f31f6
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 9604da55f339314da562cc2e162f45eed90d7f4863bdd9ea61a47b2e837611600ac9b7bba87690f52c3a0e074b6d27299ed363287c801efbed1cd645539a6b25
|
7
|
+
data.tar.gz: ad62ddbd229e6f38d2ede82e378998ea2cc3f95adf3855a02dfc3aeda6c38f44e6e2c54d6ef62b19e5d49e936e11f2e406b627a9ef74bdd3c2d06faf4c5b83b3
|
data/{LICENSE.txt → MIT-LICENSE}
RENAMED
data/README.md
CHANGED
@@ -1,89 +1,8 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
include Lolita::Billing:FirstData
|
11
|
-
|
12
|
-
# Methods for #Lolita::Billing:FirstData
|
13
|
-
#---------------------------------------
|
14
|
-
|
15
|
-
# returns integer in cents
|
16
|
-
def price
|
17
|
-
self.total_price
|
18
|
-
end
|
19
|
-
|
20
|
-
# string up to 125 symbols
|
21
|
-
# this will included in payment description
|
22
|
-
def description
|
23
|
-
"Payment to INC Lolipop"
|
24
|
-
end
|
25
|
-
|
26
|
-
# returns 3 digit string according to http://en.wikipedia.org/wiki/ISO_4217
|
27
|
-
def currency
|
28
|
-
"840"
|
29
|
-
end
|
30
|
-
|
31
|
-
# triggered when FirstData transaction is saved
|
32
|
-
def fd_trx_saved trx
|
33
|
-
case trx.status
|
34
|
-
when 'processing'
|
35
|
-
# update_attribute(:status, 'processing')
|
36
|
-
when 'completed'
|
37
|
-
# update_attribute(:status, 'completed')
|
38
|
-
when 'rejected'
|
39
|
-
# update_attribute(:status, 'rejected')
|
40
|
-
end
|
41
|
-
end
|
42
|
-
|
43
|
-
# optional
|
44
|
-
# this is called when FirstData merchant is taking some actions
|
45
|
-
# there you can save the log message other than the default log file
|
46
|
-
def log severity, message
|
47
|
-
#self.logs.create(:severity => severity, :message => message)
|
48
|
-
end
|
49
|
-
#---------------------------------------
|
50
|
-
|
51
|
-
Generate certificates by running:
|
52
|
-
|
53
|
-
rake first_data:generate_certificate
|
54
|
-
|
55
|
-
Generate certificates for both environments - test/production and specify correct merchantId.
|
56
|
-
|
57
|
-
Use `Lolita::FirstData::TestController` to pass all tests by running server and executing:
|
58
|
-
|
59
|
-
http://localhost:3000/first_data_test/test?nr=1
|
60
|
-
http://localhost:3000/first_data_test/test?nr=2
|
61
|
-
http://localhost:3000/first_data_test/test?nr=3
|
62
|
-
...
|
63
|
-
|
64
|
-
Configure your environments
|
65
|
-
|
66
|
-
# For development.rb and test.rb
|
67
|
-
#---------------------
|
68
|
-
|
69
|
-
FD_PEM = "#{Rails.root}/config/first-data/test.pem"
|
70
|
-
FD_PASS = "qwerty"
|
71
|
-
|
72
|
-
config.after_initialize do
|
73
|
-
ActiveMerchant::Billing::Base.mode = :test
|
74
|
-
end
|
75
|
-
|
76
|
-
When you are ready to pay your payment controller action should end like this:
|
77
|
-
|
78
|
-
@payment = Payment....
|
79
|
-
....
|
80
|
-
....
|
81
|
-
session[:first_data] ||= {}
|
82
|
-
session[:first_data][:billing_class] = @payment.class.to_s
|
83
|
-
session[:first_data][:billing_id] = @payment.id
|
84
|
-
session[:first_data][:finish_path] = done_payments_path
|
85
|
-
redirect_to checkout_first_data_path
|
86
|
-
|
87
|
-
### TESTS
|
88
|
-
|
89
|
-
Get source and run `rspec spec`
|
1
|
+
# LolitaFirstData
|
2
|
+
|
3
|
+
FirstData plugin for Lolita.
|
4
|
+
|
5
|
+
## ENV variables should be available
|
6
|
+
|
7
|
+
FIRST_DATA_PEM: ~/productions/shared/first_data.pem
|
8
|
+
FIRST_DATA_PASS: 123456
|
data/Rakefile
CHANGED
@@ -1,53 +1,30 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
require 'rubygems'
|
4
|
-
require 'bundler'
|
1
|
+
#!/usr/bin/env rake
|
5
2
|
begin
|
6
|
-
|
7
|
-
rescue
|
8
|
-
|
9
|
-
$stderr.puts "Run `bundle install` to install missing gems"
|
10
|
-
exit e.status_code
|
11
|
-
end
|
12
|
-
require 'rake'
|
13
|
-
|
14
|
-
require 'jeweler'
|
15
|
-
Jeweler::Tasks.new do |gem|
|
16
|
-
# gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
|
17
|
-
gem.name = "lolita-first-data"
|
18
|
-
gem.homepage = "http://github.com/ithouse/lolita-first-data"
|
19
|
-
gem.license = "MIT"
|
20
|
-
gem.summary = %Q{FirstData Payment plugin for Lolita}
|
21
|
-
gem.description = %Q{FirstData Payment plugin for Lolita using ActiveMerchant}
|
22
|
-
gem.email = "gatis@ithouse.cc"
|
23
|
-
gem.authors = ["ITHouse, Gatis Tomsons"]
|
24
|
-
# dependencies defined in Gemfile
|
25
|
-
end
|
26
|
-
Jeweler::RubygemsDotOrgTasks.new
|
27
|
-
|
28
|
-
require 'rake/testtask'
|
29
|
-
Rake::TestTask.new(:test) do |test|
|
30
|
-
test.libs << 'lib' << 'test'
|
31
|
-
test.pattern = 'test/**/test_*.rb'
|
32
|
-
test.verbose = true
|
3
|
+
require 'bundler/setup'
|
4
|
+
rescue LoadError
|
5
|
+
puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
|
33
6
|
end
|
34
|
-
|
35
|
-
require '
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
test.rcov_opts << '--exclude "gems/*"'
|
7
|
+
begin
|
8
|
+
require 'rdoc/task'
|
9
|
+
rescue LoadError
|
10
|
+
require 'rdoc/rdoc'
|
11
|
+
require 'rake/rdoctask'
|
12
|
+
RDoc::Task = Rake::RDocTask
|
41
13
|
end
|
42
14
|
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
RDoc::Task.new do |rdoc|
|
47
|
-
version = File.exist?('VERSION') ? File.read('VERSION') : ""
|
15
|
+
RDoc::Task.new(:rdoc) do |rdoc|
|
16
|
+
require "rspec/core/rake_task"
|
17
|
+
RSpec::Core::RakeTask.new(:spec)
|
48
18
|
|
19
|
+
task :default => :spec
|
49
20
|
rdoc.rdoc_dir = 'rdoc'
|
50
|
-
rdoc.title
|
51
|
-
rdoc.
|
21
|
+
rdoc.title = 'LolitaFirstData'
|
22
|
+
rdoc.options << '--line-numbers'
|
23
|
+
rdoc.rdoc_files.include('README.rdoc')
|
52
24
|
rdoc.rdoc_files.include('lib/**/*.rb')
|
53
25
|
end
|
26
|
+
|
27
|
+
APP_RAKEFILE = File.expand_path("../spec/dummy/Rakefile", __FILE__)
|
28
|
+
load 'rails/tasks/engine.rake'
|
29
|
+
|
30
|
+
Bundler::GemHelper.install_tasks
|
@@ -0,0 +1,23 @@
|
|
1
|
+
module LolitaFirstData
|
2
|
+
class ApplicationController < ActionController::Base
|
3
|
+
attr_reader :payment
|
4
|
+
include ActiveMerchant::Billing
|
5
|
+
skip_before_filter :verify_authenticity_token
|
6
|
+
|
7
|
+
private
|
8
|
+
|
9
|
+
def gateway
|
10
|
+
@gateway ||= ActiveMerchant::Billing::FirstDataGateway.new(
|
11
|
+
:pem => File.open(ENV['FIRST_DATA_PEM']).read,
|
12
|
+
:pem_password => ENV['FIRST_DATA_PASS']
|
13
|
+
)
|
14
|
+
end
|
15
|
+
|
16
|
+
# returns current payment instance from session
|
17
|
+
def set_active_payment
|
18
|
+
@payment ||= session[:payment_data][:billing_class].constantize.find(session[:payment_data][:billing_id])
|
19
|
+
rescue
|
20
|
+
render text: "No valid payment", status: 400
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,73 @@
|
|
1
|
+
module LolitaFirstData
|
2
|
+
class TestController < LolitaFirstData::ApplicationController
|
3
|
+
before_filter -> { render(nothing: true) unless Rails.env.development? }
|
4
|
+
|
5
|
+
#FIXME: it doesn't work for new gateway
|
6
|
+
# There are all 12 FirstData tests
|
7
|
+
# you should pass them to get production certificates
|
8
|
+
# use: http://localhost:3000/first_data/test?nr=1
|
9
|
+
# then increment the "nr" until done
|
10
|
+
def test
|
11
|
+
ip = params[:nr] == '9' ? '192.168.1.2' : request.remote_ip
|
12
|
+
# REQUEST
|
13
|
+
case params[:nr]
|
14
|
+
when /^(1|2|5|6|7|8|10)$/
|
15
|
+
session[:payment_data] = {}
|
16
|
+
session[:payment_data][:test] = params[:nr]
|
17
|
+
rs = gateway.purchase(100,428,client_ip_addr: ip)
|
18
|
+
if rs.success?
|
19
|
+
session[:payment_data][:trans_id] = rs.params['TRANSACTION_ID']
|
20
|
+
return redirect_to(gateway.go_out)
|
21
|
+
else
|
22
|
+
return render(:text => "<pre>#{rs.message}</pre>", :satus => 400)
|
23
|
+
end
|
24
|
+
when /^(3|4|9|11)$/
|
25
|
+
session[:payment_data] = {}
|
26
|
+
session[:payment_data][:test] = params[:nr]
|
27
|
+
rs = gateway.authorize(100,428,ip,'tests')
|
28
|
+
if rs.success?
|
29
|
+
session[:payment_data][:trans_id] = rs.params['TRANSACTION_ID']
|
30
|
+
return redirect_to(gateway.go_out)
|
31
|
+
else
|
32
|
+
return render(:text => "<pre>#{rs.message}</pre>", :satus => 400)
|
33
|
+
end
|
34
|
+
when /^(12)$/
|
35
|
+
session[:payment_data] = {}
|
36
|
+
session[:payment_data][:test] = params[:nr]
|
37
|
+
rs = gateway.close_day
|
38
|
+
return render(:text => "<pre>#{rs.message}</pre>")
|
39
|
+
end
|
40
|
+
|
41
|
+
# RESPONSE
|
42
|
+
case session[:payment_data][:test]
|
43
|
+
when /^(1|2|5|6|7|8)$/
|
44
|
+
rs = gateway.get_trans_result(ip,session[:payment_data][:trans_id])
|
45
|
+
msg = %^
|
46
|
+
trans_id: #{session[:payment_data][:trans_id]} <br />
|
47
|
+
<pre>#{rs.message}</pre>
|
48
|
+
^
|
49
|
+
return render(:text => msg)
|
50
|
+
when /^3|4|9$/
|
51
|
+
rs = gateway.complete(session[:payment_data][:trans_id],100,428,ip,'tests')
|
52
|
+
msg = %^
|
53
|
+
trans_id: #{session[:payment_data][:trans_id]} <br />
|
54
|
+
<pre>#{rs.message}</pre>
|
55
|
+
^
|
56
|
+
return render(:text => msg)
|
57
|
+
when /^(10|11)$/
|
58
|
+
if session[:payment_data][:test] == '11'
|
59
|
+
gateway.complete(session[:payment_data][:trans_id],100,428,ip,'tests')
|
60
|
+
gateway.close_day
|
61
|
+
end
|
62
|
+
rs = gateway.reverse(session[:payment_data][:trans_id],100)
|
63
|
+
msg = %^
|
64
|
+
trans_id: #{session[:payment_data][:trans_id]} <br />
|
65
|
+
<pre>#{rs.message}</pre>
|
66
|
+
^
|
67
|
+
return render(:text => msg)
|
68
|
+
end if session[:payment_data]
|
69
|
+
render :text => "USAGE: http://localhost:3000/first_data/test?nr=1", :status => 400
|
70
|
+
end
|
71
|
+
|
72
|
+
end
|
73
|
+
end
|
@@ -0,0 +1,63 @@
|
|
1
|
+
module LolitaFirstData
|
2
|
+
class TransactionsController < LolitaFirstData::ApplicationController
|
3
|
+
protect_from_forgery except: :answer
|
4
|
+
before_filter :is_ssl_required
|
5
|
+
before_filter :set_active_payment, :check_valid_payment, only: :checkout
|
6
|
+
|
7
|
+
# We get transaction_id from FirstData and if ok, then we redirect to web interface
|
8
|
+
def checkout
|
9
|
+
response = gateway.purchase(payment.price,
|
10
|
+
currency: payment.currency.to_s,
|
11
|
+
client_ip_addr: request.remote_ip,
|
12
|
+
description: payment.description,
|
13
|
+
language: payment.first_data_language)
|
14
|
+
if response[:transaction_id]
|
15
|
+
trx = LolitaFirstData::Transaction.add(payment, request, response)
|
16
|
+
redirect_to gateway.redirect_url(trx.transaction_id)
|
17
|
+
else
|
18
|
+
if request.xhr? || !request.referer
|
19
|
+
render text: I18n.t('fd.purchase_failed'), status: 400
|
20
|
+
else
|
21
|
+
flash[:error] = I18n.t('fd.purchase_failed')
|
22
|
+
redirect_to :back
|
23
|
+
end
|
24
|
+
end
|
25
|
+
ensure
|
26
|
+
LolitaFirstData.logger.info("[#{session_id}][#{payment.id}][checkout] #{response}")
|
27
|
+
end
|
28
|
+
|
29
|
+
# there we land after returning from FirstData server
|
30
|
+
# then we get transactions result and redirect to your given "finish" path
|
31
|
+
def answer
|
32
|
+
if trx = LolitaFirstData::Transaction.where(transaction_id: params[:trans_id]).first
|
33
|
+
response = gateway.result(params[:trans_id], client_ip_addr: request.remote_ip)
|
34
|
+
trx.process_result(response)
|
35
|
+
redirect_to trx.return_path
|
36
|
+
else
|
37
|
+
render text: I18n.t('fd.wrong_request'), status: 400
|
38
|
+
end
|
39
|
+
ensure
|
40
|
+
if trx
|
41
|
+
LolitaFirstData.logger.info("[#{session_id}][#{trx.paymentable_id}][answer] #{response}")
|
42
|
+
end
|
43
|
+
end
|
44
|
+
|
45
|
+
private
|
46
|
+
|
47
|
+
# payment should not be paid
|
48
|
+
def check_valid_payment
|
49
|
+
if payment.paid?
|
50
|
+
render text: I18n.t("bank_link.wrong_request"), status: 400
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
# forces SSL in production mode if available
|
55
|
+
def is_ssl_required
|
56
|
+
ssl_required(:answer, :checkout) if defined?(ssl_required) && (Rails.env.production? || Rails.env.staging?)
|
57
|
+
end
|
58
|
+
|
59
|
+
def session_id
|
60
|
+
request.session_options[:id]
|
61
|
+
end
|
62
|
+
end
|
63
|
+
end
|
@@ -0,0 +1,45 @@
|
|
1
|
+
module LolitaFirstData
|
2
|
+
class Transaction < ActiveRecord::Base
|
3
|
+
self.table_name = 'first_data_transactions'
|
4
|
+
belongs_to :paymentable, polymorphic: true
|
5
|
+
after_save :touch_paymentable
|
6
|
+
default_scope -> { order(:id) }
|
7
|
+
validates_associated :paymentable
|
8
|
+
|
9
|
+
def ip
|
10
|
+
IPAddr.new(self[:ip], Socket::AF_INET).to_s
|
11
|
+
end
|
12
|
+
|
13
|
+
def ip=(x)
|
14
|
+
self[:ip] = IPAddr.new(x).to_i
|
15
|
+
end
|
16
|
+
|
17
|
+
def process_result response
|
18
|
+
self.status = response[:result] == 'OK' ? 'completed' : 'failed'
|
19
|
+
self.transaction_code = response[:result_code]
|
20
|
+
self.save!
|
21
|
+
end
|
22
|
+
|
23
|
+
# add new transaction in Checkout
|
24
|
+
def self.add payment, request, response
|
25
|
+
LolitaFirstData::Transaction.create!(
|
26
|
+
transaction_id: response[:transaction_id],
|
27
|
+
status: 'processing',
|
28
|
+
paymentable_id: payment.id,
|
29
|
+
paymentable_type: payment.class.to_s,
|
30
|
+
ip: request.remote_ip
|
31
|
+
)
|
32
|
+
end
|
33
|
+
|
34
|
+
def return_path
|
35
|
+
paymentable.first_data_return_path
|
36
|
+
end
|
37
|
+
|
38
|
+
private
|
39
|
+
|
40
|
+
# trigger 'first_data_trx_saved' on your paymentable object
|
41
|
+
def touch_paymentable
|
42
|
+
paymentable.first_data_trx_saved(self)
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
data/config/locales/en.yml
CHANGED
@@ -1,109 +1,109 @@
|
|
1
|
-
en:
|
2
|
-
fd:
|
3
|
-
unknown_error: Unknown error
|
4
|
-
no_trans_id: No transaction ID
|
5
|
-
wrong_request: Wrong request
|
6
|
-
purchase_failed: "Failed to create a payment, please try again."
|
7
|
-
response:
|
8
|
-
code_914: "Rejected, can not return to\n original transaction"
|
9
|
-
code_003: "Confirmed VIP"
|
10
|
-
code_102: "Rejected, possible fraud detected"
|
11
|
-
code_201: "Take away, card expired"
|
12
|
-
code_300: "Status message: file action successful"
|
13
|
-
code_123: "Rejected, exceeded money\n issue frequency limit"
|
14
|
-
code_XXX: "Code to be replaced by card status code or stoplist insertion reason code"
|
15
|
-
code_915: "Rejected, reconciliation reconnection\n or checkpoint error"
|
16
|
-
code_004: "Confirmed, corrected 3rd path"
|
17
|
-
code_103: "Rejected, card holder is\n required to contact receiver bank"
|
18
|
-
code_202: "Take away, possible fraud detected"
|
19
|
-
code_301: "Status message: file action not supported by receiver"
|
20
|
-
code_400: "Confirmed (For reservation)"
|
21
|
-
code_124: "Rejected, violation of the law"
|
22
|
-
code_916: "Rejected, incorrect MAC"
|
23
|
-
code_005: "Accepted, account is selected\n by card issuer"
|
24
|
-
code_104: "Rejected, card has limits"
|
25
|
-
code_203: "Take away, card holder is\n required to contact receiver bank"
|
26
|
-
code_302: "Status message: unable to locate record on file"
|
27
|
-
code_500: "Status message: reconciled, in balance"
|
28
|
-
code_125: "Rejected, card is not valid"
|
29
|
-
code_917: "Rejected, MAC key\n synchronization error"
|
30
|
-
code_600: "Accepted (Administrative info)"
|
31
|
-
code_126: "Rejected, incorrect PIN"
|
32
|
-
code_006: "Accepted for partial sum, account\n type selected by card issuer"
|
33
|
-
code_105: "Rejected, card receiver is required\n to call the security department of the issuer bank"
|
34
|
-
code_204: "Take away, card with limits"
|
35
|
-
code_303: "Status message: duplicate record, old record replaced"
|
36
|
-
code_501: "Status message: reconciled, out of balance"
|
37
|
-
code_700: "Confirmed (commission collection)"
|
38
|
-
code_601: "Status message: impossible to trace back original transaction"
|
39
|
-
code_007: "Confirmed, corrected ICC"
|
40
|
-
code_106: "Rejected, PIN entry retry\n count exceeded"
|
41
|
-
code_205: "Take away, card receiver is required\n to call the security department of the issuer bank"
|
42
|
-
code_304: "Status message: file record field edit error"
|
43
|
-
code_502: "Status message: amount not reconciled, totals provided"
|
44
|
-
code_127: "Rejected, PIN too long"
|
45
|
-
code_920: "Rejected, security software\n error, try again"
|
46
|
-
code_918: "Rejected, no\n usable transport keys "
|
47
|
-
code_800: "Confirmed (Network management)"
|
48
|
-
code_602: "Status message: invalid transaction reference number"
|
49
|
-
code_107: "Rejected, contact\n card issuer bank"
|
50
|
-
code_206: "Take away, PIN entry\n retry count exceeded"
|
51
|
-
code_305: "Status message: file locked out"
|
52
|
-
code_503: "Status message: totals for reconciliation not available"
|
53
|
-
code_128: "Rejected, PIN key synchronization error"
|
54
|
-
code_921: "Rejected, security software error"
|
55
|
-
code_919: "Rejected, encryption key\n synchronization error"
|
56
|
-
code_900: "Message accepted, accept without\n financial responsibility"
|
57
|
-
code_603: "Status message: reference number/PAN incompatible"
|
58
|
-
code_108: "Rejected, contact card\n issuer bank, special conditions apply"
|
59
|
-
code_207: "Take away, special conditions apply"
|
60
|
-
code_306: "Status message: file action not successful"
|
61
|
-
code_504: "Status message: not reconciled, totals provided"
|
62
|
-
code_129: "Rejected, suspected counterfeit card"
|
63
|
-
code_922: "Rejected, message number\n does not comply with the order"
|
64
|
-
code_901: "Message accepted, accept with\n financial responsibility"
|
65
|
-
code_604: "Status message: POS photograph is not available"
|
66
|
-
code_110: "Rejected, incorrect amount"
|
67
|
-
code_109: "Rejected, incorrect merchant"
|
68
|
-
code_208: "Take away, lost card"
|
69
|
-
code_307: "Status message: file data format error"
|
70
|
-
code_923: "Request is being processed"
|
71
|
-
code_902: "Rejected, incorrect transaction"
|
72
|
-
code_605: "Status message: requested item supplied"
|
73
|
-
code_111: "Rejected, incorrect card number"
|
74
|
-
code_210: "Take away, suspected counterfeit card"
|
75
|
-
code_209: "Take away, card stolen"
|
76
|
-
code_308: "Status message: duplicate record, new record rejected"
|
77
|
-
code_903: "Enter transaction again"
|
78
|
-
code_606: "Status message: request cannot be\n fulfilled - required documentation is not available"
|
79
|
-
code_112: "Rejected, PIN required"
|
80
|
-
code_309: "Status message: unknown file"
|
81
|
-
code_197: "Rejected, call AMEX"
|
82
|
-
code_904: "Rejected, format error"
|
83
|
-
code_113: "Rejected, unacceptable commission"
|
84
|
-
code_198: "Rejected, contact card processing center"
|
85
|
-
code_905: "Rejected, receiving bank has no connection"
|
86
|
-
code_114: "Rejected, account type not requested"
|
87
|
-
code_906: "Rejected, currently switching"
|
88
|
-
code_115: "Rejected, requested function\n not supported"
|
89
|
-
code_950: "Rejected, business agreement breach"
|
90
|
-
code_116: "Rejected, insufficient funds"
|
91
|
-
code_907: "Rejected, issuer bank or connection\n not working"
|
92
|
-
code_117: "Rejected, incorrect PIN"
|
93
|
-
code_910: "Rejected, card issuer bank turned off"
|
94
|
-
code_908: "Rejected, transaction addressee\n not found"
|
95
|
-
code_118: "Rejected, card entry not found"
|
96
|
-
code_911: "Rejected, kartes izdevējbanka\n laicīgi nesniedz atbildi"
|
97
|
-
code_909: "Rejected, system malfunction"
|
98
|
-
code_000: "Confirmed"
|
99
|
-
code_120: "Rejected, transaction not allowed\n for terminal"
|
100
|
-
code_119: "Rejected, transaction not allowed\n for card user"
|
101
|
-
code_912: "Rejected, can not connect to\n card issuer bank"
|
102
|
-
code_001: "Confirmed, if identity can be approved"
|
103
|
-
code_100: "Rejected (General, without specification)"
|
104
|
-
code_121: "Rejected, exceeded monet\n issue limit"
|
105
|
-
code_913: "Rejected, double transmission"
|
106
|
-
code_002: "Confirmed for partial amount"
|
107
|
-
code_101: "Rejected, card expired"
|
108
|
-
code_200: "Take away card (General, without specification)"
|
109
|
-
code_122: "Rejected, security breach"
|
1
|
+
en:
|
2
|
+
fd:
|
3
|
+
unknown_error: Unknown error
|
4
|
+
no_trans_id: No transaction ID
|
5
|
+
wrong_request: Wrong request
|
6
|
+
purchase_failed: "Failed to create a payment, please try again."
|
7
|
+
response:
|
8
|
+
code_914: "Rejected, can not return to\n original transaction"
|
9
|
+
code_003: "Confirmed VIP"
|
10
|
+
code_102: "Rejected, possible fraud detected"
|
11
|
+
code_201: "Take away, card expired"
|
12
|
+
code_300: "Status message: file action successful"
|
13
|
+
code_123: "Rejected, exceeded money\n issue frequency limit"
|
14
|
+
code_XXX: "Code to be replaced by card status code or stoplist insertion reason code"
|
15
|
+
code_915: "Rejected, reconciliation reconnection\n or checkpoint error"
|
16
|
+
code_004: "Confirmed, corrected 3rd path"
|
17
|
+
code_103: "Rejected, card holder is\n required to contact receiver bank"
|
18
|
+
code_202: "Take away, possible fraud detected"
|
19
|
+
code_301: "Status message: file action not supported by receiver"
|
20
|
+
code_400: "Confirmed (For reservation)"
|
21
|
+
code_124: "Rejected, violation of the law"
|
22
|
+
code_916: "Rejected, incorrect MAC"
|
23
|
+
code_005: "Accepted, account is selected\n by card issuer"
|
24
|
+
code_104: "Rejected, card has limits"
|
25
|
+
code_203: "Take away, card holder is\n required to contact receiver bank"
|
26
|
+
code_302: "Status message: unable to locate record on file"
|
27
|
+
code_500: "Status message: reconciled, in balance"
|
28
|
+
code_125: "Rejected, card is not valid"
|
29
|
+
code_917: "Rejected, MAC key\n synchronization error"
|
30
|
+
code_600: "Accepted (Administrative info)"
|
31
|
+
code_126: "Rejected, incorrect PIN"
|
32
|
+
code_006: "Accepted for partial sum, account\n type selected by card issuer"
|
33
|
+
code_105: "Rejected, card receiver is required\n to call the security department of the issuer bank"
|
34
|
+
code_204: "Take away, card with limits"
|
35
|
+
code_303: "Status message: duplicate record, old record replaced"
|
36
|
+
code_501: "Status message: reconciled, out of balance"
|
37
|
+
code_700: "Confirmed (commission collection)"
|
38
|
+
code_601: "Status message: impossible to trace back original transaction"
|
39
|
+
code_007: "Confirmed, corrected ICC"
|
40
|
+
code_106: "Rejected, PIN entry retry\n count exceeded"
|
41
|
+
code_205: "Take away, card receiver is required\n to call the security department of the issuer bank"
|
42
|
+
code_304: "Status message: file record field edit error"
|
43
|
+
code_502: "Status message: amount not reconciled, totals provided"
|
44
|
+
code_127: "Rejected, PIN too long"
|
45
|
+
code_920: "Rejected, security software\n error, try again"
|
46
|
+
code_918: "Rejected, no\n usable transport keys "
|
47
|
+
code_800: "Confirmed (Network management)"
|
48
|
+
code_602: "Status message: invalid transaction reference number"
|
49
|
+
code_107: "Rejected, contact\n card issuer bank"
|
50
|
+
code_206: "Take away, PIN entry\n retry count exceeded"
|
51
|
+
code_305: "Status message: file locked out"
|
52
|
+
code_503: "Status message: totals for reconciliation not available"
|
53
|
+
code_128: "Rejected, PIN key synchronization error"
|
54
|
+
code_921: "Rejected, security software error"
|
55
|
+
code_919: "Rejected, encryption key\n synchronization error"
|
56
|
+
code_900: "Message accepted, accept without\n financial responsibility"
|
57
|
+
code_603: "Status message: reference number/PAN incompatible"
|
58
|
+
code_108: "Rejected, contact card\n issuer bank, special conditions apply"
|
59
|
+
code_207: "Take away, special conditions apply"
|
60
|
+
code_306: "Status message: file action not successful"
|
61
|
+
code_504: "Status message: not reconciled, totals provided"
|
62
|
+
code_129: "Rejected, suspected counterfeit card"
|
63
|
+
code_922: "Rejected, message number\n does not comply with the order"
|
64
|
+
code_901: "Message accepted, accept with\n financial responsibility"
|
65
|
+
code_604: "Status message: POS photograph is not available"
|
66
|
+
code_110: "Rejected, incorrect amount"
|
67
|
+
code_109: "Rejected, incorrect merchant"
|
68
|
+
code_208: "Take away, lost card"
|
69
|
+
code_307: "Status message: file data format error"
|
70
|
+
code_923: "Request is being processed"
|
71
|
+
code_902: "Rejected, incorrect transaction"
|
72
|
+
code_605: "Status message: requested item supplied"
|
73
|
+
code_111: "Rejected, incorrect card number"
|
74
|
+
code_210: "Take away, suspected counterfeit card"
|
75
|
+
code_209: "Take away, card stolen"
|
76
|
+
code_308: "Status message: duplicate record, new record rejected"
|
77
|
+
code_903: "Enter transaction again"
|
78
|
+
code_606: "Status message: request cannot be\n fulfilled - required documentation is not available"
|
79
|
+
code_112: "Rejected, PIN required"
|
80
|
+
code_309: "Status message: unknown file"
|
81
|
+
code_197: "Rejected, call AMEX"
|
82
|
+
code_904: "Rejected, format error"
|
83
|
+
code_113: "Rejected, unacceptable commission"
|
84
|
+
code_198: "Rejected, contact card processing center"
|
85
|
+
code_905: "Rejected, receiving bank has no connection"
|
86
|
+
code_114: "Rejected, account type not requested"
|
87
|
+
code_906: "Rejected, currently switching"
|
88
|
+
code_115: "Rejected, requested function\n not supported"
|
89
|
+
code_950: "Rejected, business agreement breach"
|
90
|
+
code_116: "Rejected, insufficient funds"
|
91
|
+
code_907: "Rejected, issuer bank or connection\n not working"
|
92
|
+
code_117: "Rejected, incorrect PIN"
|
93
|
+
code_910: "Rejected, card issuer bank turned off"
|
94
|
+
code_908: "Rejected, transaction addressee\n not found"
|
95
|
+
code_118: "Rejected, card entry not found"
|
96
|
+
code_911: "Rejected, kartes izdevējbanka\n laicīgi nesniedz atbildi"
|
97
|
+
code_909: "Rejected, system malfunction"
|
98
|
+
code_000: "Confirmed"
|
99
|
+
code_120: "Rejected, transaction not allowed\n for terminal"
|
100
|
+
code_119: "Rejected, transaction not allowed\n for card user"
|
101
|
+
code_912: "Rejected, can not connect to\n card issuer bank"
|
102
|
+
code_001: "Confirmed, if identity can be approved"
|
103
|
+
code_100: "Rejected (General, without specification)"
|
104
|
+
code_121: "Rejected, exceeded monet\n issue limit"
|
105
|
+
code_913: "Rejected, double transmission"
|
106
|
+
code_002: "Confirmed for partial amount"
|
107
|
+
code_101: "Rejected, card expired"
|
108
|
+
code_200: "Take away card (General, without specification)"
|
109
|
+
code_122: "Rejected, security breach"
|