crunchbase4 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -7
- data/README.md +14 -4
- data/lib/crunchbase.rb +1 -1
- data/lib/crunchbase/models/concerns/entity.rb +6 -1
- data/lib/crunchbase/models/organization.rb +9 -0
- data/lib/crunchbase/utilities/veriables.rb +1 -1
- data/lib/crunchbase/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cdb7c5623a3de943904cfb33279384f6af90794bd04422502300a1f3a6734fd4
|
4
|
+
data.tar.gz: dcdb6527385ea1cf7bfdf9e59b5919ccbba6239673b596b015117eae40e0ee29
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 73f00d14346138c7631c09338800ceecd2e67106351401a5c2bd7956ed53bd66d26cbfc95e52409e4e97800112cfabe4ddff3c139cbe48c4021bba0aee8760b2
|
7
|
+
data.tar.gz: dd131ff9d6f0ebcf6cf18df11b06d170db839117084bd6a6e995bbdeadffe15dda5a9a0e4b95a89c232a5efbe003c8ba0b748ac5d4e730f7522751024e44c2e1
|
data/CHANGELOG.md
CHANGED
@@ -9,12 +9,12 @@
|
|
9
9
|
* After
|
10
10
|
- Get organzation's fund: (`client.organization(entity_id, card_id: 'fund')`)
|
11
11
|
- Method for uniformly obtaining deleted entities data and support more query condition
|
12
|
-
* Get deleted
|
13
|
-
- Before: (`client.
|
12
|
+
* Get deleted organizations
|
13
|
+
- Before: (`client.deleted_organizations`)
|
14
14
|
- After : (`client.deleted_entities(collection_ids: 'organizations', limit: 20)`)
|
15
15
|
- Method for uniformly obtaining autocompletes entities data and support more query condition
|
16
|
-
* Get autocompletes
|
17
|
-
- Before: (`client.
|
16
|
+
* Get autocompletes organizations
|
17
|
+
- Before: (`client.autocomplete_organizations`)
|
18
18
|
- After : (`client.autocomplete('ekohe', collection_ids: 'organizations', limit: 3)`)
|
19
19
|
|
20
20
|
## [0.1.4] - 2020-06-12
|
@@ -38,11 +38,11 @@
|
|
38
38
|
|
39
39
|
### Added
|
40
40
|
- Implemented searches APIs to get the recent updates entities on Search
|
41
|
-
-
|
41
|
+
- organizations
|
42
42
|
- people
|
43
43
|
- funding rounds
|
44
44
|
- Implemented `autocompletes` API to allow user filter entities by keyword
|
45
|
-
-
|
45
|
+
- organizations
|
46
46
|
- people
|
47
47
|
- funding rounds
|
48
48
|
|
@@ -50,7 +50,7 @@
|
|
50
50
|
|
51
51
|
### Added
|
52
52
|
- Implemented APIs to get acquisition and investment of Entity
|
53
|
-
- Implemented APIs to search
|
53
|
+
- Implemented APIs to search organizations and funding rounds of Search
|
54
54
|
|
55
55
|
### Changed
|
56
56
|
- Refactor the API client to support search API
|
data/README.md
CHANGED
@@ -56,7 +56,7 @@ pry(main)> client = Crunchbase::Client.new
|
|
56
56
|
- [Deleted Entities](https://github.com/ekohe/crunchbase4#deleted-entities)
|
57
57
|
|
58
58
|
```ruby
|
59
|
-
<!--
|
59
|
+
<!-- Examples of organization and single card -->
|
60
60
|
response = client.organization('ekohe')
|
61
61
|
ipos = client.organization('ekohe', card_id: 'ipos')
|
62
62
|
fund = client.organization('ekohe', card_id: 'fund')
|
@@ -67,15 +67,25 @@ jobs = client.organization('ekohe', card_id: 'jobs')
|
|
67
67
|
headquarters_address = client.organization('ekohe', card_id: 'headquarters_address')
|
68
68
|
top_2_press_references = client.organization('ekohe', card_id: 'press_references', limit: 2)
|
69
69
|
|
70
|
+
<!-- Examples to get the funding rounds of the organization through paging -->
|
71
|
+
response = client.organization(
|
72
|
+
'facebook', card_id: 'participated_funding_rounds',
|
73
|
+
limit: 5,
|
74
|
+
order: 'announced_on:desc',
|
75
|
+
after_id: '3cdfcecd-5377-439b-acab-cefcf6fe21a5'
|
76
|
+
)
|
77
|
+
|
78
|
+
<!-- Examples of person and single card -->
|
79
|
+
|
70
80
|
response = client.person('mark-zuckerberg')
|
71
81
|
response = client.person('mark-zuckerberg', card_id: 'participated_investments')
|
72
|
-
response = client.funding_round('
|
73
|
-
response = client.funding_round('
|
82
|
+
response = client.funding_round('3cdfcecd-5377-439b-acab-cefcf6fe21a5')
|
83
|
+
response = client.funding_round('3cdfcecd-5377-439b-acab-cefcf6fe21a5', card_id: 'investors')
|
74
84
|
response = client.acquisition('7638eae9-07b7-4fc6-ad20-5d99de3ff928')
|
75
85
|
response = client.fund('aeaac12b-df56-7039-40f9-f1992f88e20e')
|
76
86
|
response = client.ownership('4506d9ce-85d3-4a8f-89cd-07a225359d55')
|
77
87
|
|
78
|
-
<!-- Get the JSON response of
|
88
|
+
<!-- Get the JSON response of entity -->
|
79
89
|
|
80
90
|
response.as_json
|
81
91
|
|
data/lib/crunchbase.rb
CHANGED
@@ -12,7 +12,7 @@ module Crunchbase
|
|
12
12
|
include Mappings
|
13
13
|
|
14
14
|
def fields
|
15
|
-
field_ids.map(&:to_sym)
|
15
|
+
field_ids.concat(custom_fields).map(&:to_sym)
|
16
16
|
end
|
17
17
|
|
18
18
|
def parse_response(response, request_field_ids = [], cards = [])
|
@@ -43,6 +43,11 @@ module Crunchbase
|
|
43
43
|
def as_json
|
44
44
|
fields.each_with_object({}) { |item, hash| hash[item] = send(item) }
|
45
45
|
end
|
46
|
+
|
47
|
+
private
|
48
|
+
def custom_fields
|
49
|
+
[]
|
50
|
+
end
|
46
51
|
end
|
47
52
|
end
|
48
53
|
end
|
@@ -134,6 +134,15 @@ module Crunchbase
|
|
134
134
|
headquarters_address
|
135
135
|
]
|
136
136
|
end
|
137
|
+
|
138
|
+
def employees_range
|
139
|
+
Crunchbase::Utils::NUM_EMPLOYEES_ENUM[num_employees_enum]
|
140
|
+
end
|
141
|
+
|
142
|
+
private
|
143
|
+
def custom_fields
|
144
|
+
%w[employees_range]
|
145
|
+
end
|
137
146
|
end
|
138
147
|
end
|
139
148
|
end
|
@@ -142,7 +142,7 @@ module Crunchbase
|
|
142
142
|
'online_and_on_campus' => 'Online and On Campus'
|
143
143
|
}.freeze
|
144
144
|
|
145
|
-
|
145
|
+
SCHOOL_PROGRAMS = {
|
146
146
|
'bootcamp' => 'Bootcamp',
|
147
147
|
'community_college' => 'Community College',
|
148
148
|
'four_year_university' => 'Four Year University',
|
data/lib/crunchbase/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: crunchbase4
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Encore Shao
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-11-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -196,7 +196,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
196
196
|
version: '0'
|
197
197
|
requirements: []
|
198
198
|
rubygems_version: 3.0.3
|
199
|
-
signing_key:
|
199
|
+
signing_key:
|
200
200
|
specification_version: 4
|
201
201
|
summary: Crunchbase is a ruby wrapper base on Crunchbase V4 API
|
202
202
|
test_files: []
|