tappay 0.3.1 → 0.4.0
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.
- checksums.yaml +4 -4
- data/README.md +6 -4
- data/lib/tappay.rb +2 -2
- data/lib/tappay/api_resource.rb +1 -1
- data/lib/tappay/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 88a8732b0d11ec325ad9a319ea1cf5af289238d0
|
|
4
|
+
data.tar.gz: d33b7d21f5215506ff4c5f4b2095e94654f6bd60
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1d93da6d15870ba7a31ea7c5774c9119bdd2d68c2fd49b3d99de2999872c6a00816fe9c8c6dbb55241c1e5c29912cb526df4c6328753720869b5589755bca911
|
|
7
|
+
data.tar.gz: aeaa173b34abe589cf64fadbd753018fdc03bb834334832bc4bdb1130c55c434ff4c24983bfd8b485543a3add3d800d0d12ee553f2187ce38234a72f2884136a
|
data/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# TapPay
|
|
2
2
|
|
|
3
|
-
A very simple [TapPay](https://www.tappaysdk.com/tch) API
|
|
3
|
+
A very simple [TapPay](https://www.tappaysdk.com/tch) API wrapper written in the Ruby language.
|
|
4
4
|
|
|
5
5
|
## Installation
|
|
6
6
|
|
|
@@ -23,12 +23,14 @@ See [TapPay Backend API](https://docs.tappaysdk.com/tutorial/zh/back.html#back).
|
|
|
23
23
|
|
|
24
24
|
## Usage
|
|
25
25
|
|
|
26
|
-
You
|
|
27
|
-
The partner_key and merchant_id are optional,
|
|
26
|
+
You can setup env, partner_key and merchant_id. It requests sandbox server or production server by env.
|
|
27
|
+
The partner_key and merchant_id are optional, thay could also be specified in request params.
|
|
28
28
|
|
|
29
29
|
```ruby
|
|
30
|
+
# sandbox or production
|
|
31
|
+
TapPay.env = :sandbox
|
|
32
|
+
|
|
30
33
|
TapPay.setup do |config|
|
|
31
|
-
config.env = 'test' # default: sandbox
|
|
32
34
|
config.partner_key = 'your_partner_key' # optional
|
|
33
35
|
config.merchant_id = 'your_merchant_id' # optional
|
|
34
36
|
end
|
data/lib/tappay.rb
CHANGED
|
@@ -7,7 +7,7 @@ require 'tappay/pay_by_token'
|
|
|
7
7
|
require 'tappay/refund'
|
|
8
8
|
|
|
9
9
|
module TapPay
|
|
10
|
-
@@env =
|
|
10
|
+
@@env = :sandbox
|
|
11
11
|
@@partner_key = ''
|
|
12
12
|
@@merchant_id = ''
|
|
13
13
|
|
|
@@ -17,7 +17,7 @@ module TapPay
|
|
|
17
17
|
end
|
|
18
18
|
|
|
19
19
|
def env=(env)
|
|
20
|
-
@@env = env
|
|
20
|
+
@@env = env
|
|
21
21
|
end
|
|
22
22
|
|
|
23
23
|
def partner_key=(partner_key)
|
data/lib/tappay/api_resource.rb
CHANGED
data/lib/tappay/version.rb
CHANGED