cb-api 17.3.0 → 17.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +1 -0
- data/lib/cb/config.rb +1 -0
- data/lib/cb/models/implementations/job_results_v3.rb +11 -0
- data/lib/cb/requests/job_search/get.rb +24 -0
- data/lib/cb/responses/job/search_v3.rb +28 -0
- data/lib/cb/utils/response_map.rb +2 -0
- data/lib/cb/version.rb +1 -1
- metadata +5 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ff7f7775cc735ad3cc267ed5bebb4f868d259882
|
4
|
+
data.tar.gz: 0c532e33a19b4f5bb8e0918d6332b12825dfa5b6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b7b318960c14423ba24d1a31f8c026d1d1d890a4d3dce9d494cb24451137cce2e9dc9ebef82aaa22273f31ae98560f3a47fe3641c5be79af2c3f074dc139af18
|
7
|
+
data.tar.gz: 7f5090fad7b538c6ffc86e432fe98b29e4f1fa7ad5f677b0474867f3054e43371e56396e1e0d8526c7cb51bcb9d352c12c94ab1a08274390939eca7993e6d048
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,7 @@ Version History
|
|
3
3
|
* All Version bumps are required to update this file as well!!
|
4
4
|
----
|
5
5
|
|
6
|
+
* 17.4.0 Adding job search version 3 as additional call
|
6
7
|
* 17.3.0 Set `ENV['SIMULATE_AUTH_OUTAGE']` to true to throw a `Cb::ServiceUnavailableError` for all API calls.
|
7
8
|
* 17.2.0 Give back more information about the API caller for timings
|
8
9
|
* 17.1.0 Start sending timings to all observers for API calls
|
data/lib/cb/config.rb
CHANGED
@@ -47,6 +47,7 @@ module Cb
|
|
47
47
|
@uri_employee_types ||= '/v1/employeetypes'
|
48
48
|
@uri_company_find ||= '/Employer/CompanyDetails'
|
49
49
|
@uri_job_search ||= '/v1/JobSearch'
|
50
|
+
@uri_job_search_v3 ||= '/consumer/jobs/search/'
|
50
51
|
@uri_job_find ||= '/v3/Job'
|
51
52
|
@uri_education_code ||= '/v1/EducationCodes'
|
52
53
|
@uri_recommendation_for_job ||= '/v1/Recommendations/ForJob'
|
@@ -0,0 +1,24 @@
|
|
1
|
+
module Cb
|
2
|
+
module Requests
|
3
|
+
module JobSearch
|
4
|
+
class Get < Base
|
5
|
+
|
6
|
+
def endpoint_uri
|
7
|
+
Cb.configuration.uri_job_search_v3
|
8
|
+
end
|
9
|
+
|
10
|
+
def http_method
|
11
|
+
:get
|
12
|
+
end
|
13
|
+
|
14
|
+
def headers
|
15
|
+
{
|
16
|
+
'Authorization' => args[:three_scale_token].nil? ? '' : "Bearer #{args[:three_scale_token]}",
|
17
|
+
'HostSite' => args[:host_site] || Cb.configuration.host_site,
|
18
|
+
'Accept' => 'applicatin/json;version=3.0'
|
19
|
+
}
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
module Cb
|
2
|
+
module Responses
|
3
|
+
module Job
|
4
|
+
class SearchV3 < ApiResponse
|
5
|
+
|
6
|
+
protected
|
7
|
+
|
8
|
+
def validate_api_hash
|
9
|
+
required_response_field(root_node, response)
|
10
|
+
end
|
11
|
+
|
12
|
+
def hash_containing_metadata
|
13
|
+
'search_metadata'
|
14
|
+
end
|
15
|
+
|
16
|
+
def extract_models
|
17
|
+
Models::JobResultsV3.new(response)
|
18
|
+
end
|
19
|
+
|
20
|
+
private
|
21
|
+
|
22
|
+
def root_node
|
23
|
+
'data'
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -39,6 +39,8 @@ module Cb
|
|
39
39
|
Cb::Requests::EmailSubscription::Retrieve => Cb::Responses::EmailSubscription::Response,
|
40
40
|
Cb::Requests::EmailSubscription::Modify => Cb::Responses::EmailSubscription::Response,
|
41
41
|
|
42
|
+
Cb::Requests::JobSearch::Get => Cb::Responses::Job::SearchV3,
|
43
|
+
|
42
44
|
Cb::Requests::Recommendations::Resume => Cb::Responses::Recommendations,
|
43
45
|
|
44
46
|
Cb::Requests::Resumes::Get => Cb::Responses::Resume,
|
data/lib/cb/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cb-api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 17.
|
4
|
+
version: 17.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- The CareerBuilder.com Niche and Consumer Development teams
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-08-
|
11
|
+
date: 2015-08-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httparty
|
@@ -254,6 +254,7 @@ files:
|
|
254
254
|
- lib/cb/models/implementations/job.rb
|
255
255
|
- lib/cb/models/implementations/job_branding.rb
|
256
256
|
- lib/cb/models/implementations/job_results.rb
|
257
|
+
- lib/cb/models/implementations/job_results_v3.rb
|
257
258
|
- lib/cb/models/implementations/recommended_job.rb
|
258
259
|
- lib/cb/models/implementations/resume.rb
|
259
260
|
- lib/cb/models/implementations/resume_document.rb
|
@@ -291,6 +292,7 @@ files:
|
|
291
292
|
- lib/cb/requests/education/get.rb
|
292
293
|
- lib/cb/requests/email_subscription/modify.rb
|
293
294
|
- lib/cb/requests/email_subscription/retrieve.rb
|
295
|
+
- lib/cb/requests/job_search/get.rb
|
294
296
|
- lib/cb/requests/recommendations/resume_recs.rb
|
295
297
|
- lib/cb/requests/resumes/delete.rb
|
296
298
|
- lib/cb/requests/resumes/get.rb
|
@@ -321,6 +323,7 @@ files:
|
|
321
323
|
- lib/cb/responses/errors.rb
|
322
324
|
- lib/cb/responses/industry/search.rb
|
323
325
|
- lib/cb/responses/job/search.rb
|
326
|
+
- lib/cb/responses/job/search_v3.rb
|
324
327
|
- lib/cb/responses/job/singular.rb
|
325
328
|
- lib/cb/responses/metadata.rb
|
326
329
|
- lib/cb/responses/resumes/language_codes.rb
|