Class: Crunchbase::Autocompletes::Client
- Inherits:
-
Object
- Object
- Crunchbase::Autocompletes::Client
- Includes:
- Utilities::CbModel, Utilities::Request
- Defined in:
- lib/crunchbase/autocompletes/client.rb
Overview
Send request for autocompletes endpoint
API doc:
https://app.swaggerhub.com/apis-docs/Crunchbase/crunchbase-enterprise_api/1.0.1#/Autocomplete/get_autocompletes
Constant Summary collapse
- ROOT_LIST =
'autocompletes'
- LIMIT =
25
Instance Attribute Summary collapse
-
#conditions ⇒ Object
Returns the value of attribute conditions.
-
#count ⇒ Object
Returns the value of attribute count.
-
#entities ⇒ Object
Returns the value of attribute entities.
-
#entity_type ⇒ Object
Returns the value of attribute entity_type.
-
#total_count ⇒ Object
Returns the value of attribute total_count.
Instance Method Summary collapse
-
#autocompletes ⇒ Object
Will include all attribute from API document.
-
#initialize(raw_data) ⇒ Client
constructor
A new instance of Client.
Methods included from Utilities::CbModel
cbobject, exact_kclass_object, kclass_name
Methods included from Utilities::Request
Constructor Details
#initialize(raw_data) ⇒ Client
Returns a new instance of Client.
22 23 24 25 |
# File 'lib/crunchbase/autocompletes/client.rb', line 22 def initialize(raw_data) @conditions = raw_data @entity_type = 'autocomplete_entity' end |
Instance Attribute Details
#conditions ⇒ Object
Returns the value of attribute conditions.
17 18 19 |
# File 'lib/crunchbase/autocompletes/client.rb', line 17 def conditions @conditions end |
#count ⇒ Object
Returns the value of attribute count.
17 18 19 |
# File 'lib/crunchbase/autocompletes/client.rb', line 17 def count @count end |
#entities ⇒ Object
Returns the value of attribute entities.
17 18 19 |
# File 'lib/crunchbase/autocompletes/client.rb', line 17 def entities @entities end |
#entity_type ⇒ Object
Returns the value of attribute entity_type.
17 18 19 |
# File 'lib/crunchbase/autocompletes/client.rb', line 17 def entity_type @entity_type end |
#total_count ⇒ Object
Returns the value of attribute total_count.
17 18 19 |
# File 'lib/crunchbase/autocompletes/client.rb', line 17 def total_count @total_count end |
Instance Method Details
#autocompletes ⇒ Object
Will include all attribute from API document
28 29 30 31 32 33 34 35 |
# File 'lib/crunchbase/autocompletes/client.rb', line 28 def autocompletes wrapping_autocomplete_entities!( get( ROOT_LIST, autocompletes_parameters ) ) end |