teamtailor 0.3.3 → 0.4.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: 16e2ef81d1b5db75ba273ea7d0b38d689488c57f6da278dc12eda7052136bbd0
4
- data.tar.gz: f7e0304fcc2951427ba15037bc1d6345f0afa665976537821efba7ccbbb0ded2
3
+ metadata.gz: 9c57341c9921c00f3071776c738524eb9a117066bd62d530bf580c5ee9fb5c3d
4
+ data.tar.gz: 8c4272a54dceb9c87d7d3e8008a313eb1a90737035dc467bc035123e1e0d71fd
5
5
  SHA512:
6
- metadata.gz: 8edcd6a598a1bf8298b0f47778a571652f3abb113c4952435a2f156f65650a10cf0385ac2bf5448c45dce7a5b1ab3acaddae10c287cad6a130fa2441e1421122
7
- data.tar.gz: 9b845638fef4753da98486f892ee4e35aa2eb9a37a34cf2ff63b5c571bd59f9299c6c6a322ec6d194ecd7c4223cd7969f26a9fa2f4b262047c0cbd790ea191f0
6
+ metadata.gz: '096700846b1ef8b90ac22f506d54ddfc00cbab59b083f1573b0a17967add35e9ef7fb01fc7f908e62c46379e5b431e5ee8c7c2e07a46f5e9e5dac44d3c7786a2'
7
+ data.tar.gz: 52e0e41220eb03eced02c1a9fc841c68ed14139ad9778de5601ebb3e5713a0400f909a9b7fc53725e41771f1a4c6241041211c17bcd031cab1bfa3c6681aceab
data/CHANGELOG.md CHANGED
@@ -1,6 +1,10 @@
1
1
  ## Unreleased
2
2
 
3
- ## v0.3.3 - 2021-03-11
3
+ ## v0.4.0 - 2021-09-06
4
+
5
+ - Added `Client#create_upload`
6
+
7
+ ## v0.3.3 - 2021-03-10
4
8
 
5
9
  - Added `Client#create_candidate`
6
10
  - Added `Client#create_job_application`
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- teamtailor (0.3.3)
4
+ teamtailor (0.4.0)
5
5
  typhoeus (~> 1.3.1)
6
6
 
7
7
  GEM
@@ -14,9 +14,9 @@ GEM
14
14
  safe_yaml (~> 1.0.0)
15
15
  diff-lcs (1.3)
16
16
  docile (1.3.2)
17
- ethon (0.12.0)
18
- ffi (>= 1.3.0)
19
- ffi (1.13.1)
17
+ ethon (0.14.0)
18
+ ffi (>= 1.15.0)
19
+ ffi (1.15.4)
20
20
  hashdiff (1.0.1)
21
21
  parallel (1.20.1)
22
22
  parser (3.0.0.0)
@@ -83,6 +83,23 @@ module Teamtailor
83
83
  ).call
84
84
  end
85
85
 
86
+ def create_upload(attributes:, relationships:)
87
+ Teamtailor::Request.new(
88
+ base_url: base_url,
89
+ api_token: api_token,
90
+ api_version: api_version,
91
+ path: "/v1/uploads",
92
+ method: :post,
93
+ body: {
94
+ data: {
95
+ type: "uploads",
96
+ attributes: attributes.transform_keys { |k| k.to_s.gsub("_", "-") },
97
+ relationships: relationships,
98
+ },
99
+ }
100
+ ).call
101
+ end
102
+
86
103
  def create_job_application(attributes:, relationships:)
87
104
  Teamtailor::Request.new(
88
105
  base_url: base_url,
@@ -0,0 +1,8 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "teamtailor/record"
4
+
5
+ module Teamtailor
6
+ class Upload < Record
7
+ end
8
+ end
@@ -15,6 +15,7 @@ require "teamtailor/parser/referral"
15
15
  require "teamtailor/parser/partner_result"
16
16
  require "teamtailor/parser/requisition"
17
17
  require "teamtailor/parser/requisition_step_verdict"
18
+ require "teamtailor/parser/upload"
18
19
 
19
20
  module Teamtailor
20
21
  class Parser
@@ -41,6 +42,7 @@ module Teamtailor
41
42
  when "partner-results" then Teamtailor::PartnerResult.new(record, included)
42
43
  when "requisitions" then Teamtailor::Requisition.new(record, included)
43
44
  when "requisition-step-verdicts" then Teamtailor::RequisitionStepVerdict.new(record, included)
45
+ when "uploads" then Teamtailor::Upload.new(record, included)
44
46
 
45
47
  else
46
48
  raise Teamtailor::UnknownResponseTypeError, record&.dig("type")
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Teamtailor
4
- VERSION = "0.3.3"
4
+ VERSION = "0.4.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: teamtailor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - André Ligné
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-03-10 00:00:00.000000000 Z
11
+ date: 2021-09-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec
@@ -78,6 +78,7 @@ files:
78
78
  - lib/teamtailor/parser/requisition.rb
79
79
  - lib/teamtailor/parser/requisition_step_verdict.rb
80
80
  - lib/teamtailor/parser/stage.rb
81
+ - lib/teamtailor/parser/upload.rb
81
82
  - lib/teamtailor/parser/user.rb
82
83
  - lib/teamtailor/record.rb
83
84
  - lib/teamtailor/relationship.rb