smartrecruiters 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +4 -1
- data/CHANGELOG.md +8 -0
- data/lib/smartrecruiters/objects/report_file.rb +6 -0
- data/lib/smartrecruiters/resources/candidates.rb +3 -4
- data/lib/smartrecruiters/resources/reports.rb +8 -7
- data/lib/smartrecruiters/version.rb +1 -1
- data/lib/smartrecruiters.rb +1 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 880173b6afc67da655803a5f93d354e1f1ef10d9d726b5b5942a48f73f0eb87d
|
4
|
+
data.tar.gz: d3b4f7b200d70db0481a2e414d21c01520178a4701dfa8c3186bb157e5f406eb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7eb8a0275d2e6f9070ad8314d85d319de9746485b2358353e1ba158d0a88677c1f9cc4efa03eb9a0fa1e09af4109427184d4c5899f1729a6a0c44dc95a34204f
|
7
|
+
data.tar.gz: d25bd9697ce20cb2496a1cf34df9015bc874e7acdd1174c666fb50f299a78d319edc871a59257fe6bedf0f2f74e41295edded4caffd9ac460a57335cf736b9a1
|
data/.rubocop.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,13 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
### [0.2.2](https://www.github.com/davejcameron/smartrecruiters/compare/v0.2.1...v0.2.2) (2021-10-17)
|
4
|
+
|
5
|
+
|
6
|
+
### Bug Fixes
|
7
|
+
|
8
|
+
* candidate routes and add tests ([#15](https://www.github.com/davejcameron/smartrecruiters/issues/15)) ([fe33b32](https://www.github.com/davejcameron/smartrecruiters/commit/fe33b32c4a1af521191ee976751102217a48cf5d))
|
9
|
+
* reports apis and add tests ([#17](https://www.github.com/davejcameron/smartrecruiters/issues/17)) ([47bac12](https://www.github.com/davejcameron/smartrecruiters/commit/47bac1240a1a4495e883afa7e26de1312c97ddda))
|
10
|
+
|
3
11
|
### [0.2.1](https://www.github.com/davejcameron/smartrecruiters/compare/v0.2.0...v0.2.1) (2021-10-13)
|
4
12
|
|
5
13
|
|
@@ -21,7 +21,6 @@ module SmartRecruiters
|
|
21
21
|
|
22
22
|
def delete(candidate_id:)
|
23
23
|
delete_request("candidates/#{candidate_id}")
|
24
|
-
true
|
25
24
|
end
|
26
25
|
|
27
26
|
def retrieve_consent(candidate_id:)
|
@@ -29,8 +28,7 @@ module SmartRecruiters
|
|
29
28
|
end
|
30
29
|
|
31
30
|
def retrieve_consents(candidate_id:)
|
32
|
-
|
33
|
-
Collection.from_response(response, type: Object.new)
|
31
|
+
Object.new get_request("candidates/#{candidate_id}/consents").body
|
34
32
|
end
|
35
33
|
|
36
34
|
def retrieve_application(candidate_id:, job_id:)
|
@@ -43,7 +41,8 @@ module SmartRecruiters
|
|
43
41
|
end
|
44
42
|
|
45
43
|
def retrieve_status_history(candidate_id:, job_id:)
|
46
|
-
|
44
|
+
response = get_request("candidates/#{candidate_id}/jobs/#{job_id}/status/history")
|
45
|
+
Collection.from_response(response, type: Object)
|
47
46
|
end
|
48
47
|
end
|
49
48
|
end
|
@@ -2,30 +2,31 @@
|
|
2
2
|
|
3
3
|
module SmartRecruiters
|
4
4
|
class ReportsResource < Resource
|
5
|
-
REPORT_API = 'reporting-api/v201804'
|
5
|
+
REPORT_API = 'reporting-api/v201804/reports'
|
6
6
|
def list(**params)
|
7
|
-
response = get_request(
|
7
|
+
response = get_request(REPORT_API.to_s, params: params)
|
8
8
|
Collection.from_response(response, type: Report)
|
9
9
|
end
|
10
10
|
|
11
11
|
def retrieve(report_id:)
|
12
|
-
Report.new get_request("#{REPORT_API}
|
12
|
+
Report.new get_request("#{REPORT_API}/#{report_id}").body
|
13
13
|
end
|
14
14
|
|
15
15
|
def retrieve_files(report_id:)
|
16
|
-
|
16
|
+
response = get_request("#{REPORT_API}/#{report_id}/files")
|
17
|
+
Collection.from_response(response, type: ReportFile)
|
17
18
|
end
|
18
19
|
|
19
20
|
def generate_report(report_id:)
|
20
|
-
Report.new post_request("#{REPORT_API}
|
21
|
+
Report.new post_request("#{REPORT_API}/#{report_id}/files", body: {}).body
|
21
22
|
end
|
22
23
|
|
23
24
|
def retrieve_recent_file(report_id:)
|
24
|
-
|
25
|
+
ReportFile.new get_request("#{REPORT_API}/#{report_id}/files/recent").body
|
25
26
|
end
|
26
27
|
|
27
28
|
def retrieve_recent_file_data(report_id:)
|
28
|
-
response = get_request("#{REPORT_API}
|
29
|
+
response = get_request("#{REPORT_API}/#{report_id}/files/recent/data").body
|
29
30
|
Object.new JSON.parse(response)
|
30
31
|
end
|
31
32
|
end
|
data/lib/smartrecruiters.rb
CHANGED
@@ -18,6 +18,7 @@ module SmartRecruiters
|
|
18
18
|
autoload :Offer, 'smartrecruiters/objects/offer'
|
19
19
|
autoload :User, 'smartrecruiters/objects/user'
|
20
20
|
autoload :Report, 'smartrecruiters/objects/report'
|
21
|
+
autoload :ReportFile, 'smartrecruiters/objects/report_file'
|
21
22
|
autoload :Review, 'smartrecruiters/objects/review'
|
22
23
|
autoload :SystemRole, 'smartrecruiters/objects/system_role'
|
23
24
|
autoload :Webhook, 'smartrecruiters/objects/webhook'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: smartrecruiters
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Cameron
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-10-
|
11
|
+
date: 2021-10-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -112,6 +112,7 @@ files:
|
|
112
112
|
- lib/smartrecruiters/objects/job.rb
|
113
113
|
- lib/smartrecruiters/objects/offer.rb
|
114
114
|
- lib/smartrecruiters/objects/report.rb
|
115
|
+
- lib/smartrecruiters/objects/report_file.rb
|
115
116
|
- lib/smartrecruiters/objects/review.rb
|
116
117
|
- lib/smartrecruiters/objects/system_role.rb
|
117
118
|
- lib/smartrecruiters/objects/user.rb
|