Class: Glassnode::RESTv1
- Inherits:
-
Object
- Object
- Glassnode::RESTv1
- Includes:
- RESTClient, RESTv1Addresses, RESTv1Blockchain, RESTv1Defi, RESTv1Derivatives, RESTv1Distribution, RESTv1Entities, RESTv1Eth2, RESTv1Fees, RESTv1Indicators, RESTv1Institutions, RESTv1Lightning, RESTv1Market, RESTv1Mempool, RESTv1Mining, RESTv1Protocols, RESTv1Supply, RESTv1Transactions
- Defined in:
- lib/rest/v1.rb
Instance Attribute Summary collapse
-
#api_endpoint ⇒ Object
Returns the value of attribute api_endpoint.
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#debug ⇒ Object
Returns the value of attribute debug.
-
#debug_connection ⇒ Object
Returns the value of attribute debug_connection.
-
#proxy ⇒ Object
Returns the value of attribute proxy.
-
#rest_open_timeout ⇒ Object
Returns the value of attribute rest_open_timeout.
-
#rest_timeout ⇒ Object
Returns the value of attribute rest_timeout.
Instance Method Summary collapse
- #config ⇒ Object
-
#initialize(args = {}) ⇒ RESTv1
constructor
A new instance of RESTv1.
Methods included from RESTv1Mempool
#fees_average_relative, #fees_distribution, #fees_median_relative, #fees_sum, #txs_count_distribution, #txs_count_sum, #txs_size_distribution, #txs_size_sum, #txs_value_distribution, #txs_value_sum
Methods included from RESTv1Lightning
#base_fee_median, #channel_size_mean, #channel_size_median, #channels_count, #fee_rate_median, #gini_capacity_distribution, #gini_channel_distribution, #network_capacity_sum, #node_connectivity, #nodes_count
Methods included from RESTv1Defi
Methods included from RESTv1Institutions
#iq3_btcq_aum_sum, #iq3_btcq_flows_sum, #iq3_btcq_holdings_sum, #iq3_btcq_market_price_usd, #iq3_btcq_outstanding_units_sum, #iq3_btcq_premium_percent, #iq3_ethq_aum_sum, #iq3_ethq_flows_sum, #iq3_ethq_holdings_sum, #iq3_ethq_market_price_usd, #iq3_ethq_outstanding_units_sum, #iq3_ethq_premium_percent, #iq3_qbtc_aum_sum, #iq3_qbtc_flows_sum, #iq3_qbtc_holdings_sum, #iq3_qbtc_market_price_usd, #iq3_qbtc_outstanding_units_sum, #iq3_qbtc_premium_percent, #iq3_qeth_aum_sum, #iq3_qeth_flows_sum, #iq3_qeth_holdings_sum, #iq3_qeth_market_price_usd, #iq3_qeth_outstanding_units_sum, #iq3_qeth_premium_percent, #purpose_etf_aum_sum, #purpose_etf_flows_sum, #purpose_etf_holdings_sum, #qbtc_aum_sum, #qbtc_flows_sum, #qbtc_holdings_sum, #qbtc_market_price_usd, #qbtc_premium_percent
Methods included from RESTv1Protocols
#uniswap_liquidity_latest, #uniswap_transaction_count, #uniswap_volume_sum
Methods included from RESTv1Derivatives
#futures_annualized_basis_3m, #futures_estimated_leverage_ratio, #futures_funding_rate_perpetual, #futures_funding_rate_perpetual_all, #futures_liquidated_volume_long_mean, #futures_liquidated_volume_long_relative, #futures_liquidated_volume_long_sum, #futures_liquidated_volume_short_mean, #futures_liquidated_volume_short_sum, #futures_open_interest_cash_margin_sum, #futures_open_interest_crypto_margin_relative, #futures_open_interest_crypto_margin_sum, #futures_open_interest_latest, #futures_open_interest_perpetual_sum, #futures_open_interest_perpetual_sum_all, #futures_open_interest_sum, #futures_open_interest_sum_all, #futures_term_structure, #futures_term_structure_by_exchange, #futures_volume_daily_latest, #futures_volume_daily_perpetual_sum, #futures_volume_daily_perpetual_sum_all, #futures_volume_daily_sum, #futures_volume_daily_sum_all, #options_25delta_skew_1_month, #options_25delta_skew_1_week, #options_25delta_skew_3_months, #options_25delta_skew_6_months, #options_25delta_skew_all, #options_atm_implied_volatility_1_month, #options_atm_implied_volatility_1_week, #options_atm_implied_volatility_3_months, #options_atm_implied_volatility_6_months, #options_atm_implied_volatility_all, #options_open_interest_distribution, #options_open_interest_put_call_ratio, #options_open_interest_sum, #options_volume_daily_sum, #options_volume_put_call_ratio
Methods included from RESTv1Eth2
#deposited_by_provider_volume_sum, #staking_deposits_count, #staking_phase_0_goal_percent, #staking_total_deposits_count, #staking_total_validators_count, #staking_total_volume_sum, #staking_validators_count, #staking_volume_sum
Methods included from RESTv1Market
#amer_30d_price_change, #apac_30d_price_change, #deltacap_usd, #emea_30d_price_change, #marketcap_realized_usd, #marketcap_usd, #mvrv, #mvrv_less_155, #mvrv_more_155, #mvrv_z_score, #price_drawdown_relative, #price_realized_usd, #price_usd, #price_usd_close, #price_usd_ohlc
Methods included from RESTv1Supply
#active_1d_1w, #active_1m_3m, #active_1w_1m, #active_1y_2y, #active_24h, #active_2y_3y, #active_3m_6m, #active_3y_5y, #active_5y_7y, #active_6m_12m, #active_7y_10y, #active_more_10y, #active_more_1y_percent, #active_more_2y_percent, #active_more_3y_percent, #active_more_5y_percent, #burned, #current, #current_adjusted, #highly_liquid_sum, #hodl_waves, #illiquid_change, #illiquid_sum, #inflation_rate, #issued, #liquid_change, #liquid_illiquid_sum, #liquid_sum, #loss_sum, #lth_loss_sum, #lth_net_change, #lth_profit_sum, #lth_sth_profit_loss_relative, #lth_sum, #minted, #profit_relative, #profit_sum, #rcap_hodl_waves, #revived_more_1y_sum, #revived_more_2y_sum, #revived_more_3y_sum, #revived_more_5y_sum, #sth_loss_sum, #sth_lth_realized_value_ratio, #sth_profit_loss_ratio, #sth_profit_sum, #sth_sum, #supply_by_txout_type
Methods included from RESTv1Distribution
#balance_1pct_holders, #balance_exchanges, #balance_exchanges_all, #balance_exchanges_relative, #balance_luna_foundation_guard, #balance_miners_all, #balance_miners_change, #balance_miners_sum, #balance_mtgox_trustee, #balance_otc_desks, #balance_wbtc, #exchange_net_position_change, #gini, #herfindahl, #supply_contracts
Methods included from RESTv1Blockchain
#block_count, #block_height, #block_interval_mean, #block_interval_median, #block_size_mean, #block_size_sum, #utxo_count, #utxo_created_count, #utxo_created_value_mean, #utxo_created_value_median, #utxo_created_value_sum, #utxo_loss_count, #utxo_profit_count, #utxo_profit_relative, #utxo_spent_count, #utxo_spent_value_mean, #utxo_spent_value_median, #utxo_spent_value_sum
Methods included from RESTv1Indicators
#accumulation_trend_score, #asol, #asol_account_based, #average_dormancy, #average_dormancy_supply_adjusted, #balanced_price_usd, #bvin, #cdd, #cdd90, #cdd90_account_based_age_adjusted, #cdd90_age_adjusted, #cdd_account_based, #cdd_supply_adjusted, #cdd_supply_adjusted_binary, #cvdd, #cyd, #cyd_account_based, #cyd_account_based_supply_adjusted, #cyd_supply_adjusted, #difficulty_ribbon, #difficulty_ribbon_compression, #dormancy_account_based, #dormancy_flow, #hash_ribbon, #hodled_lost_coins, #hodler_net_position_change, #investor_capitalization, #liveliness, #liveliness_account_based, #msol, #msol_account_based, #mvrv_account_based, #net_realized_profit_loss, #net_unrealized_profit_loss, #net_unrealized_profit_loss_account_based, #nupl_less_155, #nupl_less_155_account_based, #nupl_more_155, #nupl_more_155_account_based, #nvt, #nvt_entity_adjusted, #nvts, #pi_cycle_top, #puell_multiple, #rcap_account_based, #realized_loss, #realized_profit, #realized_profit_loss_ratio, #realized_profits_to_value_ratio, #reserve_risk, #rhodl_ratio, #seller_exhaustion_constant, #soab, #sol_1d_1w, #sol_1h, #sol_1h_24h, #sol_1m_3m, #sol_1w_1m, #sol_1y_2y, #sol_2y_3y, #sol_3m_6m, #sol_3y_5y, #sol_5y_7y, #sol_6m_12m, #sol_7y_10y, #sol_more_10y, #sopr, #sopr_account_based, #sopr_adjusted, #sopr_less_155, #sopr_more_155, #spent_output_price_distribution_ath, #spent_output_price_distribution_percent, #ssr, #ssr_oscillator, #stock_to_flow_deflection, #stock_to_flow_ratio, #svab, #svl_1d_1w, #svl_1h, #svl_1h_24h, #svl_1m_3m, #svl_1w_1m, #svl_1y_2y, #svl_2y_3y, #svl_3m_6m, #svl_3y_5y, #svl_5y_7y, #svl_6m_12m, #svl_7y_10y, #svl_more_10y, #unrealized_loss, #unrealized_loss_account_based, #unrealized_profit, #unrealized_profit_account_based, #urpd_entity_adjusted, #utxo_realized_price_distribution_ath, #utxo_realized_price_distribution_percent, #velocity
Methods included from RESTv1Fees
#exchanges_mean, #exchanges_relative, #exchanges_sum, #fee_ratio_multiple, #gas_limit_tx_mean, #gas_limit_tx_median, #gas_price_mean, #gas_price_median, #gas_used_mean, #gas_used_median, #gas_used_sum, #tx_types_breakdown_relative, #tx_types_breakdown_sum, #volume_mean, #volume_median, #volume_sum
Methods included from RESTv1Transactions
#contract_calls_external_count, #contract_calls_internal_count, #count, #entity_adjusted_count, #rate, #segwit_adoption, #size_mean, #size_sum, #spent_output_types_share, #taproot_adoption, #transfers_between_exchanges_count, #transfers_count, #transfers_exchanges_to_whales_count, #transfers_from_exchanges_count, #transfers_from_miners_count, #transfers_from_otc_desks_count, #transfers_rate, #transfers_to_exchanges_count, #transfers_to_miners_count, #transfers_to_otc_desks_count, #transfers_volume_adjusted_mean, #transfers_volume_adjusted_median, #transfers_volume_adjusted_sum, #transfers_volume_between_exchanges_sum, #transfers_volume_by_size_entity_adjusted_relative, #transfers_volume_by_size_entity_adjusted_sum, #transfers_volume_entity_adjusted_mean, #transfers_volume_entity_adjusted_median, #transfers_volume_entity_adjusted_sum, #transfers_volume_exchanges_net, #transfers_volume_exchanges_to_whales_sum, #transfers_volume_from_exchanges_mean, #transfers_volume_from_exchanges_sum, #transfers_volume_from_miners_sum, #transfers_volume_from_otc_desks_sum, #transfers_volume_loss_sum, #transfers_volume_mean, #transfers_volume_median, #transfers_volume_miners_net, #transfers_volume_miners_to_exchanges, #transfers_volume_miners_to_exchanges_all, #transfers_volume_profit_relative, #transfers_volume_profit_sum, #transfers_volume_sum, #transfers_volume_to_exchanges_mean, #transfers_volume_to_exchanges_sum, #transfers_volume_to_miners_sum, #transfers_volume_to_otc_desks_sum, #transfers_volume_whales_to_exchanges_sum, #transfers_volume_within_exchanges_sum, #transfers_whales_to_exchanges_count, #tx_types_breakdown_count, #tx_types_breakdown_relative
Methods included from RESTv1Mining
#difficulty_latest, #difficulty_mean, #hash_rate_mean, #marketcap_thermocap_ratio, #miners_outflow_multiple, #miners_unspent_supply, #revenue_from_fees, #revenue_sum, #thermocap, #volume_mined_sum
Methods included from RESTv1Entities
#active_count, #min_1k_count, #net_growth_count, #new_count, #profit_relative, #receiving_count, #sending_count, #supply_balance_0001_001, #supply_balance_001_01, #supply_balance_01_1, #supply_balance_100_1k, #supply_balance_10_100, #supply_balance_10k_100k, #supply_balance_1_10, #supply_balance_1k_10k, #supply_balance_less_0001, #supply_balance_more_100k, #supply_distribution_relative
Methods included from RESTv1Addresses
#accumulation_balance, #accumulation_count, #active_count, #count, #loss_count, #min_100_count, #min_100_usd_count, #min_100k_usd_count, #min_10_count, #min_10_usd_count, #min_10k_count, #min_10k_usd_count, #min_1_count, #min_1_usd_count, #min_1k_count, #min_1k_usd_count, #min_1m_usd_count, #min_32_count, #min_point_1_count, #min_point_zero_1_count, #new_non_zero_count, #non_zero_count, #profit_count, #profit_relative, #receiving_count, #receiving_from_exchanges_count, #sending_count, #sending_to_exchanges_count, #supply_balance_0001_001, #supply_balance_001_01, #supply_balance_01_1, #supply_balance_100_1k, #supply_balance_10_100, #supply_balance_10k_100k, #supply_balance_1_10, #supply_balance_1k_10k, #supply_balance_less_0001, #supply_balance_more_100k, #supply_distribution_relative
Methods included from RESTClient
Constructor Details
#initialize(args = {}) ⇒ RESTv1
Returns a new instance of RESTv1.
46 47 48 49 50 51 52 53 |
# File 'lib/rest/v1.rb', line 46 def initialize(args = {}) self.api_endpoint = args[:url] ? "#{args[:url]}/v1/" : "https://api.glassnode.com/v1/" self.proxy = args[:proxy] || nil self.debug_connection = false self.rest_timeout = 30 self.rest_open_timeout = 30 self.api_key = args[:api_key] end |
Instance Attribute Details
#api_endpoint ⇒ Object
Returns the value of attribute api_endpoint.
23 24 25 |
# File 'lib/rest/v1.rb', line 23 def api_endpoint @api_endpoint end |
#api_key ⇒ Object
Returns the value of attribute api_key.
25 26 27 |
# File 'lib/rest/v1.rb', line 25 def api_key @api_key end |
#debug ⇒ Object
Returns the value of attribute debug.
23 24 25 |
# File 'lib/rest/v1.rb', line 23 def debug @debug end |
#debug_connection ⇒ Object
Returns the value of attribute debug_connection.
23 24 25 |
# File 'lib/rest/v1.rb', line 23 def debug_connection @debug_connection end |
#proxy ⇒ Object
Returns the value of attribute proxy.
24 25 26 |
# File 'lib/rest/v1.rb', line 24 def proxy @proxy end |
#rest_open_timeout ⇒ Object
Returns the value of attribute rest_open_timeout.
24 25 26 |
# File 'lib/rest/v1.rb', line 24 def rest_open_timeout @rest_open_timeout end |
#rest_timeout ⇒ Object
Returns the value of attribute rest_timeout.
24 25 26 |
# File 'lib/rest/v1.rb', line 24 def rest_timeout @rest_timeout end |
Instance Method Details
#config ⇒ Object
55 56 57 58 59 60 61 62 63 64 |
# File 'lib/rest/v1.rb', line 55 def config { :api_endpoint => self.api_endpoint, :debug_connection => self.debug_connection, :rest_timeout => self.rest_timeout, :rest_open_timeout => self.rest_open_timeout, :proxy => self.proxy, :api_key => self.api_key } end |