trustly-client-ruby 0.1.93 → 0.1.95
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 +11 -0
- data/lib/trustly/api/signed.rb +2 -2
- data/lib/trustly/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: 1ca0b42d0ed2a2793b928d62a44a3a949e32ef37
|
|
4
|
+
data.tar.gz: 14995d2e5daa4531ca2cc20c3c3ccdf1c4c042ec
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 5a4e58710183dbf99bf11cfb5fbc227f9d51293f586c3585ca273ffabff8ed8696f092c90ce598cc2e35dc1c6ad1d85d4333d77096e2ea76b41c402e2c2e813c
|
|
7
|
+
data.tar.gz: ff610742c28461585a7126844d4ba0a7e6afaf6c6659edcfa8d16f7af26ebc197955a1094b8e4d4b8460f54772e375de41ff4849a3a7869d4630f526308cd444
|
data/README.md
CHANGED
|
@@ -125,6 +125,17 @@ You can check if there was an error:
|
|
|
125
125
|
|
|
126
126
|
### Refund call
|
|
127
127
|
|
|
128
|
+
Required parameters:
|
|
129
|
+
|
|
130
|
+
- OrderID
|
|
131
|
+
- Amount
|
|
132
|
+
- Currency / default to "EUR"
|
|
133
|
+
|
|
134
|
+
Example:
|
|
135
|
+
|
|
136
|
+
```ruby
|
|
137
|
+
> api.refund({"OrderID"=>2205700591,"Amount"=>3,"Currency"=>"EUR"})
|
|
138
|
+
```
|
|
128
139
|
|
|
129
140
|
|
|
130
141
|
### Notifications
|
data/lib/trustly/api/signed.rb
CHANGED
|
@@ -112,13 +112,13 @@ class Trustly::Api::Signed < Trustly::Api
|
|
|
112
112
|
|
|
113
113
|
def refund(_options)
|
|
114
114
|
options = {
|
|
115
|
-
"
|
|
115
|
+
"Currency" => "EUR"
|
|
116
116
|
}.merge(_options)
|
|
117
117
|
|
|
118
118
|
# check for required options
|
|
119
119
|
["OrderID","Amount","Currency"].each{|req_attr| raise Trustly::Exception::DataError, "Option not valid '#{req_attr}'" if options.try(:[],req_attr).nil? }
|
|
120
120
|
|
|
121
|
-
request = Trustly::Data::JSONRPCRequest.new('
|
|
121
|
+
request = Trustly::Data::JSONRPCRequest.new('Refund',options,nil)
|
|
122
122
|
return self.call_rpc(request)
|
|
123
123
|
end
|
|
124
124
|
|
data/lib/trustly/version.rb
CHANGED