synapse_payments 0.8.1 → 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 25a612034d8cfee2d2523e9e2374c528a3d624d9
4
- data.tar.gz: c913ea8c14a87a87ac6e94801fd8e69ec78ad884
3
+ metadata.gz: 6e19445a449894bb263dbefc9ec9de55a269a78d
4
+ data.tar.gz: ba81c9bf397d457d2bba4c5b071553e0ef096739
5
5
  SHA512:
6
- metadata.gz: 942ee39e5ae8f09e853cd9b592171e5010f60944ad6f7e6a65a347f8b05c9022ece823aa2d8ae501cc01394e89b8a21a4566ed4141c55540e09ae3ac800c1cf9
7
- data.tar.gz: 60e104bcb5ac4c8350763ec2a849a66b1d80bdb09a9035f3f8ebec8e3c68b2ff70a6e62b070231e4f4acf7033ab47d0cfc6c3657d012a51bc67c0a2bf2d8fc29
6
+ metadata.gz: 864733c89e1c880ff0113b72c4abf273eb4fb9cf297687b7f6d452a5a4a2566e2c0a28a13a8f18baeff96d5b56c81c3e064c82b93d9bdc45b8ccc8e3994b4bff
7
+ data.tar.gz: d6bc784aea3c72536b427f886349ebd450a99291b1cdd1cbaefd0c0c5d6f03d56472ea44f944956398989410a2acf79f7d939f1b8db4ec8bafd70b6b041ac8d0
@@ -23,11 +23,11 @@ module SynapsePayments
23
23
  amount: amount,
24
24
  currency: currency
25
25
  },
26
- extra: {
27
- ip: ip_address
28
- }.merge(args)
26
+ extra: (args[:extra] || {}).merge({ ip: ip_address })
29
27
  }
30
28
 
29
+ data = data.merge(fees: args[:fees]) if args[:fees]
30
+
31
31
  @client.post(path: "/users/#{@user_id}/nodes/#{@node_id}/trans", oauth_key: @oauth_key, fingerprint: @fingerprint, json: data)
32
32
  end
33
33
 
@@ -1,3 +1,3 @@
1
1
  module SynapsePayments
2
- VERSION = "0.8.1"
2
+ VERSION = "0.9.0"
3
3
  end
data/samples.md CHANGED
@@ -198,7 +198,23 @@ response = user_client.send_money(
198
198
  to_node_type: 'SYNAPSE-US',
199
199
  amount: 24.00,
200
200
  currency: 'USD',
201
- ip_address: '192.168.0.1'
201
+ ip_address: '192.168.0.1',
202
+ )
203
+ ```
204
+
205
+ There are optional parameters that can be specified:
206
+
207
+ ```ruby
208
+ response = user_client.send_money(
209
+ # ...
210
+ extra: {
211
+ supp_id: 'my_id'
212
+ },
213
+ fees: [
214
+ {
215
+ # ...
216
+ }
217
+ ]
202
218
  )
203
219
  ```
204
220
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: synapse_payments
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.1
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Javier Julio
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-04-25 00:00:00.000000000 Z
11
+ date: 2016-05-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler