currency-rate 1.5.2 → 1.5.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/adapters/crypto/yadio_adapter.rb +18 -0
- data/lib/currency_rate/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 52b476d5c2345bf38f2e09f6e97e1aa7d6a31fa7ac599be78d3010d51d02bd4e
|
4
|
+
data.tar.gz: 98ea03b4216397d3a15089d4811707b8dd45a61ad762e97306822139152a564f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9022611b0da6b1744aadbbce03134a39fbb8fbafe18eef681b1a544378b92408045af7aef0cc1f88baade2dafe02f9df9b5fc5c75b75f3375648664e882e8697
|
7
|
+
data.tar.gz: c1db1e408e49c28cd88c44a1c5705daccaf26e79733c6cb6fac2c9baac2143a256814bfd825c56e3de7d07e63d332ef3bdb302ad11b876e12f8c61a09b24342b
|
@@ -0,0 +1,18 @@
|
|
1
|
+
module CurrencyRate
|
2
|
+
class YadioAdapter < Adapter
|
3
|
+
SUPPORTED_CURRENCIES = %w(VES)
|
4
|
+
|
5
|
+
ANCHOR_CURRENCY = "BTC"
|
6
|
+
|
7
|
+
FETCH_URL = "https://api.yadio.io/rate/BTC"
|
8
|
+
|
9
|
+
def normalize(data)
|
10
|
+
return nil unless super
|
11
|
+
|
12
|
+
{
|
13
|
+
"anchor" => ANCHOR_CURRENCY,
|
14
|
+
"VES" => BigDecimal(data["rate"].to_s),
|
15
|
+
}
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: currency-rate
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Roman Snitko
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-11-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: http
|
@@ -111,6 +111,7 @@ files:
|
|
111
111
|
- lib/adapters/crypto/kraken_adapter.rb
|
112
112
|
- lib/adapters/crypto/localbitcoins_adapter.rb
|
113
113
|
- lib/adapters/crypto/okcoin_adapter.rb
|
114
|
+
- lib/adapters/crypto/yadio_adapter.rb
|
114
115
|
- lib/adapters/fiat/bonbast_adapter.rb
|
115
116
|
- lib/adapters/fiat/coinmonitor_adapter.rb
|
116
117
|
- lib/adapters/fiat/currency_layer_adapter.rb
|