przelewy24 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/przelewy24/ekspres/client.rb +32 -0
- data/lib/przelewy24/version.rb +1 -1
- data/lib/przelewy24.rb +1 -0
- data/przelewy24.gemspec +2 -0
- metadata +19 -2
@@ -0,0 +1,32 @@
|
|
1
|
+
require 'savon'
|
2
|
+
|
3
|
+
module Przelewy24
|
4
|
+
module Ekspres
|
5
|
+
class Client
|
6
|
+
def initialize(login, password)
|
7
|
+
@login = login
|
8
|
+
@password = password
|
9
|
+
end
|
10
|
+
|
11
|
+
def register_transfer(transaction)
|
12
|
+
client.call(:register_transfer, message: {
|
13
|
+
'authorizeIn' => authorization_object,
|
14
|
+
'o_transactionIn' => transaction
|
15
|
+
})
|
16
|
+
end
|
17
|
+
|
18
|
+
private
|
19
|
+
|
20
|
+
def client
|
21
|
+
@client ||= Savon::Client.new(wsdl: 'https://ekspres.przelewy24.pl/wsdl/pay/service_sandbox.php?wsdl')
|
22
|
+
end
|
23
|
+
|
24
|
+
def authorization_object
|
25
|
+
{
|
26
|
+
login: @login,
|
27
|
+
pass: @password
|
28
|
+
}
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
data/lib/przelewy24/version.rb
CHANGED
data/lib/przelewy24.rb
CHANGED
data/przelewy24.gemspec
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: przelewy24
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-
|
12
|
+
date: 2015-06-12 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|
@@ -43,6 +43,22 @@ dependencies:
|
|
43
43
|
- - ~>
|
44
44
|
- !ruby/object:Gem::Version
|
45
45
|
version: '10.0'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: savon
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
50
|
+
requirements:
|
51
|
+
- - ~>
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '2.0'
|
54
|
+
type: :runtime
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ~>
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '2.0'
|
46
62
|
description: Integration with Przelewy24 payment gateway.
|
47
63
|
email:
|
48
64
|
- m.mlozniak@gmail.com
|
@@ -62,6 +78,7 @@ files:
|
|
62
78
|
- bin/setup
|
63
79
|
- lib/przelewy24.rb
|
64
80
|
- lib/przelewy24/client.rb
|
81
|
+
- lib/przelewy24/ekspres/client.rb
|
65
82
|
- lib/przelewy24/invalid_gateway_url.rb
|
66
83
|
- lib/przelewy24/response.rb
|
67
84
|
- lib/przelewy24/transaction.rb
|