Class: Jet::Client::Taxonomy
- Inherits:
-
Object
- Object
- Jet::Client::Taxonomy
- Defined in:
- lib/jet/client/taxonomy.rb
Instance Method Summary collapse
- #get_links(limit, offset, version = "v1") ⇒ Object
- #get_node(node_url) ⇒ Object
- #get_node_attributes(node_url) ⇒ Object
-
#initialize(client) ⇒ Taxonomy
constructor
A new instance of Taxonomy.
Constructor Details
#initialize(client) ⇒ Taxonomy
Returns a new instance of Taxonomy.
4 5 6 |
# File 'lib/jet/client/taxonomy.rb', line 4 def initialize(client) @client = client end |
Instance Method Details
#get_links(limit, offset, version = "v1") ⇒ Object
8 9 10 11 |
# File 'lib/jet/client/taxonomy.rb', line 8 def get_links(limit, offset, version = "v1") params = { limit: limit, offset: offset } @client.rest_get_with_token("/taxonomy/links/#{version}", params) end |
#get_node(node_url) ⇒ Object
13 14 15 |
# File 'lib/jet/client/taxonomy.rb', line 13 def get_node(node_url) @client.rest_get_with_token(node_url) end |
#get_node_attributes(node_url) ⇒ Object
17 18 19 |
# File 'lib/jet/client/taxonomy.rb', line 17 def get_node_attributes(node_url) @client.rest_get_with_token("#{node_url}/attributes") end |