fuly 0.0.10 → 0.0.12
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/lib/bitfinex/api/funding.rb +4 -2
- data/lib/bitfinex/api/wallet.rb +7 -7
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4ed6618d4430916ccdf37b24a4916957c3912d62d6deafb9ca56e4d8b5747afe
|
|
4
|
+
data.tar.gz: be28ea133ac9b9bdf47c094fccb070fdeee92f208205dfdde498d221394b6215
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: bbdbea345ecfbd67d553651cd15323d3097e25fe909db16a9ce84c6420abd2c1432d76ef4182b5ace2722198e06fd2b4bb5258b913abd5941d6ec58cc7519d4f
|
|
7
|
+
data.tar.gz: 5bbb059a25bfe9d8f2293890463ee6e5061d2e5664eb0440eb788f5c2744bea802b4f9f54e070810a33667dfe76a6b6b11cd0b7c4b21cc58f2d0e35bddd02987
|
data/lib/bitfinex/api/funding.rb
CHANGED
|
@@ -45,14 +45,16 @@ module Bitfinex
|
|
|
45
45
|
# https://docs.bitfinex.com/reference#submit-funding-offer
|
|
46
46
|
def funding_create_offer(currency, amount, rate, period)
|
|
47
47
|
# auth/w/funding/offer/submit
|
|
48
|
-
request("auth/w/funding/offer/submit", {
|
|
48
|
+
res = request("auth/w/funding/offer/submit", {
|
|
49
49
|
type: "LIMIT",
|
|
50
50
|
symbol: currency, #fUSD
|
|
51
51
|
amount: amount, #借款要是負的
|
|
52
52
|
rate: rate,
|
|
53
53
|
period: period,
|
|
54
|
-
flags:
|
|
54
|
+
flags: 64,
|
|
55
55
|
}).body
|
|
56
|
+
res = JSON.parse(res)
|
|
57
|
+
return res
|
|
56
58
|
end
|
|
57
59
|
|
|
58
60
|
# https://docs.bitfinex.com/v1/reference#rest-auth-offers
|
data/lib/bitfinex/api/wallet.rb
CHANGED
|
@@ -17,21 +17,21 @@ module Bitfinex
|
|
|
17
17
|
# https://docs.bitfinex.com/reference#rest-auth-withdraw
|
|
18
18
|
def withdraw(wallet, method, amount, address)
|
|
19
19
|
res = request("auth/w/withdraw", {
|
|
20
|
-
wallet: wallet
|
|
21
|
-
method: method
|
|
22
|
-
amount: amount
|
|
23
|
-
address: address#'0x2bf788d017C4DF927787DF2EB1310266d9db6893',
|
|
20
|
+
wallet: wallet, #'exchange',
|
|
21
|
+
method: method, #'tetheruse',
|
|
22
|
+
amount: amount, #'10',
|
|
23
|
+
address: address, #'0x2bf788d017C4DF927787DF2EB1310266d9db6893',
|
|
24
24
|
}).body
|
|
25
25
|
return JSON.parse(res)
|
|
26
26
|
end
|
|
27
|
-
|
|
27
|
+
|
|
28
28
|
# Ratelimit: 45 req/min
|
|
29
29
|
# https://docs.bitfinex.com/reference#rest-auth-movements
|
|
30
30
|
def movements
|
|
31
31
|
res = request("auth/r/movements/hist").body
|
|
32
32
|
return JSON.parse(res)
|
|
33
33
|
end
|
|
34
|
-
|
|
34
|
+
|
|
35
35
|
# Ratelimit: 45 req/min
|
|
36
36
|
# https://docs.bitfinex.com/reference#rest-auth-wallets
|
|
37
37
|
def wallets
|
|
@@ -44,7 +44,7 @@ module Bitfinex
|
|
|
44
44
|
def ledgers(currency)
|
|
45
45
|
res = request("auth/r/ledgers/#{currency}/hist", {
|
|
46
46
|
limit: 2500,
|
|
47
|
-
|
|
47
|
+
# category: 28,
|
|
48
48
|
}).body
|
|
49
49
|
return JSON.parse(res)
|
|
50
50
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fuly
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.12
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Rex Chen
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2022-05-15 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: httparty
|