cb-api 20.5.0 → 20.6.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 +2 -1
- data/lib/cb/clients/saved_jobs.rb +56 -0
- data/lib/cb/config.rb +1 -0
- data/lib/cb/convenience.rb +4 -0
- data/lib/cb/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0ebf3d91e8e5051506d3abae76a85f6b6899a7eb
|
4
|
+
data.tar.gz: 487c0fd6cfdc67f2cc986e5ed3dd7e79f40a1942
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7fca2ea3870480e5ff88df8b0dd78603984278589ee4fcdc1e0e8f9b6d88beb2affac3244484468e7bbe2dec2d35fdaea5dfd4cd8b3aa7a5f07f47d6d9c81135
|
7
|
+
data.tar.gz: b33e15bdab0b83e59b3c3e7b8f6a267dfa9c2f346fefa9093309e6b42a70fc481bc336a17b338ab2e1795747da82b706da8c389c18019d683cd1465806feb00a
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,7 @@ Version History
|
|
2
2
|
====
|
3
3
|
* All Version bumps are required to update this file as well!!
|
4
4
|
----
|
5
|
+
* 20.6.0 Add new saved jobs API (/consumer/saved-jobs)
|
5
6
|
* 20.5.0 Adding resume insights client
|
6
7
|
* 20.4.0 Add posting_date to recommendations for job model.
|
7
8
|
* 20.3.0 Add new resume list API (/consumer/resumes)
|
@@ -65,4 +66,4 @@ Version History
|
|
65
66
|
* 13.0.1 This change is to turn off metadata parsing and raise exception if the api response does not contain metadata.
|
66
67
|
* This means we can optionally control wether or not a specific API call expects metadata to come back
|
67
68
|
* 13.0.0 Adds a new resume recommendations call and removes the old one *(BREAKING)*
|
68
|
-
* https://github.com/
|
69
|
+
* https://github.com/careerbuilder/ruby-cb-api/pull/154/files
|
@@ -0,0 +1,56 @@
|
|
1
|
+
# Copyright 2016 CareerBuilder, LLC
|
2
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
3
|
+
# you may not use this file except in compliance with the License.
|
4
|
+
# You may obtain a copy of the License at
|
5
|
+
#
|
6
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
7
|
+
# Unless required by applicable law or agreed to in writing, software
|
8
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
9
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
10
|
+
# See the License for the specific language governing permissions and limitations under the License.
|
11
|
+
require_relative 'base'
|
12
|
+
module Cb
|
13
|
+
module Clients
|
14
|
+
class SavedJobs < Base
|
15
|
+
class << self
|
16
|
+
def get(args = {})
|
17
|
+
uri = Cb.configuration.uri_saved_job
|
18
|
+
uri += "/#{ args[:id] }" if args[:id]
|
19
|
+
cb_client.cb_get(uri, headers: headers(args))
|
20
|
+
end
|
21
|
+
|
22
|
+
def create(args = {})
|
23
|
+
cb_client.cb_put(Cb.configuration.uri_saved_job,
|
24
|
+
body: body(args),
|
25
|
+
headers: headers(args))
|
26
|
+
end
|
27
|
+
|
28
|
+
def delete(args = {})
|
29
|
+
cb_client.cb_delete(uri_with_id(args), body: body(args), headers: headers(args))
|
30
|
+
end
|
31
|
+
|
32
|
+
def update(args = {})
|
33
|
+
cb_client.cb_post(uri_with_id(args), body: body(args), headers: headers(args))
|
34
|
+
end
|
35
|
+
|
36
|
+
private
|
37
|
+
|
38
|
+
def uri_with_id(args)
|
39
|
+
"#{ Cb.configuration.uri_saved_job }/#{ args[:id] }"
|
40
|
+
end
|
41
|
+
|
42
|
+
def body(args)
|
43
|
+
body = {}
|
44
|
+
body[:id] = args[:id] if args[:id]
|
45
|
+
body[:job_id] = args[:job_id] if args[:job_id]
|
46
|
+
body[:job_title] = args[:job_title] if args[:job_title]
|
47
|
+
body[:notes] = args[:notes] if args[:notes]
|
48
|
+
body[:status] = args[:status] if args[:status]
|
49
|
+
body[:application_date] = args[:application_date] if args[:application_date]
|
50
|
+
body[:site] = args[:site] if args[:site]
|
51
|
+
body.to_json
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
data/lib/cb/config.rb
CHANGED
@@ -99,6 +99,7 @@ module Cb
|
|
99
99
|
@uri_saved_search_list ||= '/cbapi/savedsearches'
|
100
100
|
@uri_subscription_retrieve ||= '/v2/user/subscription/retrieve'
|
101
101
|
@uri_subscription_modify ||= '/v2/user/subscription'
|
102
|
+
@uri_saved_job ||= '/consumer/saved-jobs'
|
102
103
|
@uri_saved_job_search_create ||= '/v2/savedsearch/create'
|
103
104
|
@uri_state_list ||= '/ajax/citysuggest.aspx'
|
104
105
|
@uri_tn_join_questions ||= '/talentnetwork/config/join/questions'
|
data/lib/cb/convenience.rb
CHANGED
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: 20.
|
4
|
+
version: 20.6.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: 2016-03-
|
11
|
+
date: 2016-03-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httparty
|
@@ -226,6 +226,7 @@ files:
|
|
226
226
|
- lib/cb/clients/recommendation.rb
|
227
227
|
- lib/cb/clients/resume_insights.rb
|
228
228
|
- lib/cb/clients/resumes.rb
|
229
|
+
- lib/cb/clients/saved_jobs.rb
|
229
230
|
- lib/cb/clients/saved_search.rb
|
230
231
|
- lib/cb/clients/talent_network.rb
|
231
232
|
- lib/cb/clients/user.rb
|