Class: ArkEcosystem::Client::API::Delegates
- Defined in:
- lib/arkecosystem/client/api/delegates.rb
Overview
Methods for the Delegates API
Instance Method Summary collapse
-
#all(parameters = {}) ⇒ Faraday::Response
Get all delegates.
-
#blocks(id, parameters = {}) ⇒ Faraday::Response
Get the blocks for the given delegate.
-
#show(id) ⇒ Faraday::Response
Get the delegate by the given id.
-
#voters(id, parameters = {}) ⇒ Faraday::Response
Get the votes for the given delegate.
Methods inherited from Base
Constructor Details
This class inherits a constructor from ArkEcosystem::Client::API::Base
Instance Method Details
#all(parameters = {}) ⇒ Faraday::Response
Get all delegates.
13 14 15 |
# File 'lib/arkecosystem/client/api/delegates.rb', line 13 def all(parameters = {}) @client.get('delegates', parameters) end |
#blocks(id, parameters = {}) ⇒ Faraday::Response
Get the blocks for the given delegate.
32 33 34 |
# File 'lib/arkecosystem/client/api/delegates.rb', line 32 def blocks(id, parameters = {}) @client.get("delegates/#{id}/blocks", parameters) end |
#show(id) ⇒ Faraday::Response
Get the delegate by the given id.
22 23 24 |
# File 'lib/arkecosystem/client/api/delegates.rb', line 22 def show(id) @client.get("delegates/#{id}") end |
#voters(id, parameters = {}) ⇒ Faraday::Response
Get the votes for the given delegate.
42 43 44 |
# File 'lib/arkecosystem/client/api/delegates.rb', line 42 def voters(id, parameters = {}) @client.get("delegates/#{id}/voters", parameters) end |