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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 35dbd16179a1352655a1e6518ce77b5cabc94640
4
- data.tar.gz: c2fb3ec3b7ecf5a3d72f2250af50e397f391ed4d
3
+ metadata.gz: 1ca0b42d0ed2a2793b928d62a44a3a949e32ef37
4
+ data.tar.gz: 14995d2e5daa4531ca2cc20c3c3ccdf1c4c042ec
5
5
  SHA512:
6
- metadata.gz: 74b944a5e2c88fd1be319f58aa06492a9b36d259958df7ccf43072de05c806ed44abf4ce9cecbf680e29799930317044af44ff273443aabba4a91e73aa5179ef
7
- data.tar.gz: 9842909db8c228aff9e7750b54aedfef2704a9a22d3f5ef36692dc48606eebe0dbc5c803783c0dd0843a446619adb0bf0ba3ebf31770d91521e0c04be0f96060
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
@@ -112,13 +112,13 @@ class Trustly::Api::Signed < Trustly::Api
112
112
 
113
113
  def refund(_options)
114
114
  options = {
115
- "OrderID" => "EUR"
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('Deposit',options,nil)
121
+ request = Trustly::Data::JSONRPCRequest.new('Refund',options,nil)
122
122
  return self.call_rpc(request)
123
123
  end
124
124
 
@@ -1,3 +1,3 @@
1
1
  module Trustly
2
- VERSION = "0.1.93"
2
+ VERSION = "0.1.95"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trustly-client-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.93
4
+ version: 0.1.95
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jorge Carretie