cb-api 22.10.0 → 23.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: efea2932b1fe7ead7c7738a8844d762ba43e57d93321b823e3e6055d4df3e196
4
- data.tar.gz: 7e950fcdbe096c8f24733f6b77bc2edef4ba71abf0addf20728757de1b10f47c
3
+ metadata.gz: 43a1aebb02ccca729a245879847354949cf08feaf4d36b0d2ef2e5d90b844caa
4
+ data.tar.gz: 1a5eda1c9db2928d202c12036e08138914f44cbf57036ef3a2104071700d9443
5
5
  SHA512:
6
- metadata.gz: 066226b7eabbe76e5d959953dcb6c1b0b5f6312387ba2ba83fd33254dcf9d49cb63b4e7b8f35163d36a86cd8ac56f51f5f4aee48f8f20671d4ae71fd86a63519
7
- data.tar.gz: e281d3dbc06ce25be43d3bacba2f2277db7914f78f5627286e1a17f38b4d9233c7c457c77a435363a16503c0da6b2fcf9d05b9c83f7e1e9dc75a15119161ca84
6
+ metadata.gz: 1021ba898c4caae0a8519ae7aefeff56a9492fd3c1c4e944a58b26be7d6481cca40de51433a20e0ada083109b3ecb260fc7f47a4729b413a621386fbe69e4a88
7
+ data.tar.gz: 78ccc5c628e58fcf699ed20dd1c3b5396544c63028a8e3d70f5d55748c1829ae0a6a6c12b22504804560cfed66a5fc5bee3fdae0ae8fdbdbc7eeebca0118570d
@@ -2,6 +2,7 @@ Version History
2
2
  ====
3
3
  * All Version bumps are required to update this file as well!!
4
4
  ----
5
+ * 23.0.0 Add oauth token as param for retrieval of job
5
6
  * 22.10.0 Updated uri_job_find endpoint
6
7
  * 22.9.0 Add SiteID to XML sent for Anonymous Saved Search
7
8
  * 22.8.0 Allow optional override of Accept header
@@ -13,8 +13,8 @@ module Cb
13
13
  module Clients
14
14
  class Job < Base
15
15
  class << self
16
- def get(args = {})
17
- response = cb_client.cb_get(Cb.configuration.uri_job_find, query: args)
16
+ def get(oauth_token, args = {})
17
+ response = cb_client.cb_get(uri_get(args[:did]), headers: headers(oauth_token), query: args)
18
18
  not_found_check(response)
19
19
  response
20
20
  end
@@ -25,6 +25,18 @@ module Cb
25
25
 
26
26
  private
27
27
 
28
+ def uri_get job_id
29
+ "#{Cb.configuration.uri_job_find}/#{job_id}"
30
+ end
31
+
32
+ def headers(oauth_token)
33
+ {
34
+ 'Accept' => 'application/json',
35
+ 'Authorization' => "Bearer #{ oauth_token }",
36
+ 'Content-Type' => 'application/json'
37
+ }
38
+ end
39
+
28
40
  def not_found_check(response)
29
41
  return if response.nil?
30
42
  errors = Cb::Responses::Errors.new(response['ResponseJob'], false).parsed.join
@@ -9,5 +9,5 @@
9
9
  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10
10
  # See the License for the specific language governing permissions and limitations under the License.
11
11
  module Cb
12
- VERSION = '22.10.0'
12
+ VERSION = '23.0.0'
13
13
  end
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: 22.10.0
4
+ version: 23.0.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: 2018-12-05 00:00:00.000000000 Z
11
+ date: 2018-12-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty