paya 0.9.8 → 0.9.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +71 -8
- data/lib/paya/version.rb +1 -1
- data/paya.gemspec +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 97dd6f6ba88e6b7922fd421e79b61dda73a8625d
|
4
|
+
data.tar.gz: 8aa8f162fb4326324cba88b46c085851a7c15ff6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 40e44c27c4ce30df2cd092bba2454e4f193084df3d2555de835cc99d0e8392369cbb0f8765996773f730db484d9d6bf8a99447a1716b55b99b77386572ef9a10
|
7
|
+
data.tar.gz: 849b82c58974f248cc49aef37794acc4de1310b2bfa53241868c4e0cbc2e555e86762f3f696dbf63504f402982c7ea1e3b0f815a7a2c35432c508b70bf7da90a
|
data/README.md
CHANGED
@@ -19,17 +19,80 @@ Or install it yourself as:
|
|
19
19
|
|
20
20
|
## Usage
|
21
21
|
|
22
|
-
Generate a new
|
22
|
+
Generate a new initializer file in config/initializers folder with your paya credentials and terminal ids using following command.
|
23
23
|
|
24
|
-
|
25
|
-
require 'securerandom'
|
24
|
+
$ rails generate paya:install
|
26
25
|
|
27
|
-
|
28
|
-
Paya.password = "YOUR_PASSWORD"
|
29
|
-
Paya.production = false
|
30
|
-
|
31
|
-
After that, you can process payment according to your requirements.
|
26
|
+
To get paya credentials and terminal ids, contact with Paya development team at https://paya.com/developers
|
32
27
|
|
28
|
+
After that, you can process CCD, PPD, TEL or WEB based ACH payment according to your requirements. There are seperate methods and classes to process each payment type
|
29
|
+
|
30
|
+
Below is simple example of processing single CCD check
|
31
|
+
|
32
|
+
paya = Paya::Base.new
|
33
|
+
options = {
|
34
|
+
transaction_id: '',
|
35
|
+
request_id: '',
|
36
|
+
first_name: '',
|
37
|
+
......
|
38
|
+
}
|
39
|
+
identifier = 'R' # Other possible options include 'A', 'V', 'F', 'O', 'P' etc
|
40
|
+
single_ccd_check = paya.process_single_ccd_check options, identifier
|
41
|
+
# Response has has two main hashes, one is request xml sent to paya server and other is paya server response
|
42
|
+
|
43
|
+
request_xml = single_ccd_check[:request]
|
44
|
+
response = single_ccd_check[:response]
|
45
|
+
|
46
|
+
Similarly you can process PPD check
|
47
|
+
|
48
|
+
paya = Paya::Base.new
|
49
|
+
options = {
|
50
|
+
transaction_id: '',
|
51
|
+
request_id: '',
|
52
|
+
first_name: '',
|
53
|
+
......
|
54
|
+
}
|
55
|
+
identifier = 'R' # Other possible options include 'A', 'V', 'F', 'O', 'P' etc
|
56
|
+
single_ppd_check = paya.process_single_ppd_check options, identifier
|
57
|
+
# single_ppd_check hash has has two main hashes, one is request xml sent to paya server and other is paya server response
|
58
|
+
|
59
|
+
request_xml = single_ppd_check[:request]
|
60
|
+
response = single_ppd_check[:response]
|
61
|
+
|
62
|
+
There are also certification/development methods available
|
63
|
+
|
64
|
+
paya = Paya::Base.new
|
65
|
+
options = {
|
66
|
+
transaction_id: '',
|
67
|
+
request_id: '',
|
68
|
+
first_name: '',
|
69
|
+
......
|
70
|
+
}
|
71
|
+
terminal_id = REQUIRED-TERMINAL-ID
|
72
|
+
identifier = 'R' # Other possible options include 'A', 'V', 'F', 'O', 'P' etc
|
73
|
+
|
74
|
+
paya.process_single_certification_check options, terminal_id, identifier
|
75
|
+
|
76
|
+
To process advance level payments, there are methods available in individual classes for CCD, PPD, TEL and WEB
|
77
|
+
|
78
|
+
options = {
|
79
|
+
transaction_id: '',
|
80
|
+
request_id: '',
|
81
|
+
first_name: '',
|
82
|
+
......
|
83
|
+
}
|
84
|
+
|
85
|
+
guaranteed_cedit_debit_ccd_payment = Paya::Ccd::Guaranteed::CreditDebitTransaction.new options
|
86
|
+
|
87
|
+
check_no_verification_dl_optional = guaranteed_cedit_debit_ccd_payment.check_no_verification_dl_optional
|
88
|
+
# check_no_verification_dl_optional hash has has two main hashes, one is request xml sent to paya server and other is paya server response
|
89
|
+
|
90
|
+
request_xml = check_no_verification_dl_optional[:request]
|
91
|
+
response = check_no_verification_dl_optional[:response]
|
92
|
+
|
93
|
+
Above example would automatically pick terminal id from configuration file.
|
94
|
+
|
95
|
+
Similarly there are classes/methods available for Guaranteed/Non Guaranteed Credit Debit and Debit only transactions for CCD, PPD, WEB and TEL
|
33
96
|
|
34
97
|
## Development
|
35
98
|
|
data/lib/paya/version.rb
CHANGED
data/paya.gemspec
CHANGED
@@ -11,7 +11,7 @@ Gem::Specification.new do |spec|
|
|
11
11
|
|
12
12
|
spec.summary = %q{Ruby wrapper for Paya ACH payment gateway integration}
|
13
13
|
spec.description = %q{Ruby wrapper for Paya ACH payment gateway integration. This is developed by reading Paya documentation and is not official team of Paya}
|
14
|
-
spec.homepage = "https://github.com/mshahzadtariq"
|
14
|
+
spec.homepage = "https://github.com/mshahzadtariq/paya"
|
15
15
|
spec.license = "MIT"
|
16
16
|
|
17
17
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: paya
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shahzad Tariq
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-10-
|
11
|
+
date: 2018-10-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -96,7 +96,7 @@ files:
|
|
96
96
|
- lib/paya/web/non_guaranteed/credit_debit_transaction.rb
|
97
97
|
- lib/paya/web/non_guaranteed/debit_transaction.rb
|
98
98
|
- paya.gemspec
|
99
|
-
homepage: https://github.com/mshahzadtariq
|
99
|
+
homepage: https://github.com/mshahzadtariq/paya
|
100
100
|
licenses:
|
101
101
|
- MIT
|
102
102
|
metadata: {}
|