diff --git a/lib/zaif.rb b/lib/zaif.rb index 8bbe5ed..4f8bdef 100644 --- a/lib/zaif.rb +++ b/lib/zaif.rb @@ -62,6 +62,18 @@ def get_depth(currency_code, counter_currency_code = "jpy") return json end + # Get currency pairs of *currency_code* / *counter_currency_code*. + # @param [String] currency_code Base currency code + # @param [String] counter_currency_code Counter currency code + def get_currency_pairs(currency_code, counter_currency_code = "jpy") + currency_pair = currency_code + unless currency_code=='all' + currency_pair += "_" + counter_currency_code + end + json = get_ssl(@zaif_public_url + "currency_pairs/" + currency_pair) + return json + end + # # Trade API #