Added Status identifier when calling cryptocompare API

This commit is contained in:
Julien Eluard 2017-10-12 19:09:14 +02:00 committed by Roman Volosovskyi
parent a8bb85fc72
commit 990232782f
1 changed files with 2 additions and 1 deletions

View File

@ -11,9 +11,10 @@
;; (get-prices "ETH" "USD" println print) ;; (get-prices "ETH" "USD" println print)
(def api-url "https://min-api.cryptocompare.com/data") (def api-url "https://min-api.cryptocompare.com/data")
(def status-identifier "extraParams=Status.im")
(defn- gen-price-url [fsyms tsyms] (defn- gen-price-url [fsyms tsyms]
(str api-url "/pricemultifull?fsyms=" fsyms "&tsyms=" tsyms)) (str api-url "/pricemultifull?fsyms=" fsyms "&tsyms=" tsyms "&" status-identifier))
(defn- format-price-resp [from to resp] (defn- format-price-resp [from to resp]
(let [raw (:RAW (types/json->clj resp)) (let [raw (:RAW (types/json->clj resp))