payment-manager-client 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/payment/manager/client.rb +5 -0
- data/lib/payment/manager/client/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c399d0336423ed9916451406bd1611b57185734e
|
4
|
+
data.tar.gz: 516b3250021a7874bf2179ba3068b7aa70812772
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 602b3bb4fd2a79892f3059fd4e077b4ce31a53da936a072d7820ffd88b932eba14ea937e247e8466ee3651889060cecfe411063a733fb91550215699c193f602
|
7
|
+
data.tar.gz: d7a0019d5381b16c81c676a60994ab281d7e7e4adcc7fbcbe047d044da107f16e25b741a94373e2eb1aaf950353f4484939fb4bb2cd9c326ef4324619f5d319b
|
@@ -34,6 +34,11 @@ module Payment
|
|
34
34
|
response = Payment::Manager::Request.get(config.api_url + '/api/plans', params)
|
35
35
|
JSON.parse(response.body)
|
36
36
|
end
|
37
|
+
|
38
|
+
def valid_token?(token)
|
39
|
+
response = Payment::Manager::Request.get(config.api_url + "/api/tokens/validate/#{config.client_id}/#{token}", {})
|
40
|
+
JSON.parse(response.body)['valid']
|
41
|
+
end
|
37
42
|
end
|
38
43
|
end
|
39
44
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: payment-manager-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kaio Magalhães
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-12-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|