paysera 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -2
- data/lib/paysera/response.rb +1 -1
- data/lib/paysera/version.rb +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: d227a2e0f5394c6116579926b5d93c545c93ee74
|
4
|
+
data.tar.gz: 93cb81e905d3081e9f4498f373305f037ccb9344
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 09fc1ddd0b029a9c9f82f6ad965de33a97affeecac38101780df7a58a022eb0773a5e93b1814ba0cc7b6e44468a392cabac317c0fc76571d9ca69cfb41e09752
|
7
|
+
data.tar.gz: 2f5ee5a5125b1f3fdc8253186702c4323e910b023b26bb0b036f9e3d0558e1e9ef7086b088da56b528a75204df28023095ef3b6a262ecdcf764d1ed6553d60c3
|
data/README.md
CHANGED
@@ -47,8 +47,9 @@ request_params_example = {
|
|
47
47
|
cancelurl: 'http://0.0.0.0:3000?cancel',
|
48
48
|
callbackurl: 'http://0.0.0.0:3000?callback'
|
49
49
|
}
|
50
|
-
Paysera::Request.build_request(request_params_example,
|
50
|
+
Paysera::Request.build_request(request_params_example, sign_password: 'my_sign_password')
|
51
51
|
```
|
52
|
+
*sign_password* is optional.
|
52
53
|
|
53
54
|
It will generate payment link to paysera - `https://paysera.lt/pay/?data=...&sign=...`.
|
54
55
|
So you can do this if you are using *Rails*:
|
@@ -68,8 +69,9 @@ If you specify `projectid` or `sign_password` it will overwrite the values set
|
|
68
69
|
|
69
70
|
```ruby
|
70
71
|
# params should include valid data, ss1 and ss2
|
71
|
-
response = Paysera::Response.new(params,
|
72
|
+
response = Paysera::Response.new(params, projectid: 123, sign_password: 'my_sign_password')
|
72
73
|
```
|
74
|
+
*projectid* and *sign_password* are optional.
|
73
75
|
|
74
76
|
If `ss1` or `ss2` fails to validate a `Paysera::Error::Response` exception will be raised with a specific error message.
|
75
77
|
|
data/lib/paysera/response.rb
CHANGED
@@ -6,7 +6,7 @@ require 'base64'
|
|
6
6
|
|
7
7
|
module Paysera
|
8
8
|
class Response
|
9
|
-
PAYSERA_PUBLIC_KEY = 'http://
|
9
|
+
PAYSERA_PUBLIC_KEY = 'http://www.paysera.com/download/public.key'
|
10
10
|
|
11
11
|
def initialize(query, projectid: nil, sign_password: nil)
|
12
12
|
raise send_error("'data' parameter was not found") if query[:data].nil?
|
data/lib/paysera/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: paysera
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tomas Achmedovas
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-08-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -94,7 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
94
94
|
version: '0'
|
95
95
|
requirements: []
|
96
96
|
rubyforge_project:
|
97
|
-
rubygems_version: 2.4.
|
97
|
+
rubygems_version: 2.4.8
|
98
98
|
signing_key:
|
99
99
|
specification_version: 4
|
100
100
|
summary: Paysera.com payment API
|