open_api_smart_recruiters_sdk 0.2.4 → 0.2.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (36) hide show
  1. checksums.yaml +4 -4
  2. data/.DS_Store +0 -0
  3. data/Gemfile.lock +1 -1
  4. data/lib/.DS_Store +0 -0
  5. data/lib/smart_recruiters/.DS_Store +0 -0
  6. data/lib/smart_recruiters/api/interview_types_api.rb +169 -0
  7. data/lib/smart_recruiters/api/interviews_api.rb +296 -0
  8. data/lib/smart_recruiters/api/messages_api.rb +187 -0
  9. data/lib/smart_recruiters/api/statuses_api.rb +215 -0
  10. data/lib/smart_recruiters/api/timeslots_api.rb +261 -0
  11. data/lib/smart_recruiters/configuration.rb +1 -1
  12. data/lib/smart_recruiters/models/applications.rb +192 -0
  13. data/lib/smart_recruiters/models/attendee_status.rb +202 -0
  14. data/lib/smart_recruiters/models/attendee_status_value.rb +21 -0
  15. data/lib/smart_recruiters/models/candidate_attendee_status_value.rb +22 -0
  16. data/lib/smart_recruiters/models/context.rb +197 -0
  17. data/lib/smart_recruiters/models/interview.rb +305 -0
  18. data/lib/smart_recruiters/models/interview_to_update_input.rb +216 -0
  19. data/lib/smart_recruiters/models/interview_type.rb +188 -0
  20. data/lib/smart_recruiters/models/interview_types.rb +192 -0
  21. data/lib/smart_recruiters/models/interviewer.rb +216 -0
  22. data/lib/smart_recruiters/models/interviewers.rb +192 -0
  23. data/lib/smart_recruiters/models/interviews_list.rb +199 -0
  24. data/lib/smart_recruiters/models/message.rb +222 -0
  25. data/lib/smart_recruiters/models/message_details.rb +206 -0
  26. data/lib/smart_recruiters/models/message_view.rb +233 -0
  27. data/lib/smart_recruiters/models/messages_view.rb +192 -0
  28. data/lib/smart_recruiters/models/share_with.rb +233 -0
  29. data/lib/smart_recruiters/models/timeslot.rb +275 -0
  30. data/lib/smart_recruiters/models/timeslots.rb +192 -0
  31. data/lib/smart_recruiters/models/user_id.rb +189 -0
  32. data/lib/smart_recruiters/models/uuid_read_only.rb +188 -0
  33. data/lib/smart_recruiters/models/visibility.rb +21 -0
  34. data/lib/smart_recruiters/version.rb +1 -1
  35. data/lib/smart_recruiters.rb +2 -19
  36. metadata +31 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 439f69e8d60e69b97fe4653a60036b44ed682a19c91db7483c447ef7530dfdbd
4
- data.tar.gz: 3de01e25124ed31b652458fa548c73602f200f8479bd10fa93cfdaf97826ffda
3
+ metadata.gz: 55bc321bdccf9e7206ba3dc274d72e6d6e5f28a78ddb876a22ebec9ed70f37b8
4
+ data.tar.gz: 9349206d09604b08a559d8c4bfa841c5107081918765c1e4927271005bd77cd9
5
5
  SHA512:
6
- metadata.gz: 6599f826b2a0e1b5e400cab4cace8aa24e6cc055a2c24d977d7b399f1a56db22f4623b3291f53cf2aff6e672bdf918783cef1958c533041dd70d605593947c19
7
- data.tar.gz: 8766458b663269de4ff7f8b4a85487346b2d2d332f748067dbd7dd227fd78549a3482342b96c40a113a8a1359948e25196c639dacfd611e1a30a3d2b647239cd
6
+ metadata.gz: fee60a515a78d07f4e5e468097ab891418386db5415849060c270c2e61a4fd227a116cdba864c65ff1fdf912e51a8d2074036f343deaceee48b3bad0b3edae58
7
+ data.tar.gz: c38c6b24f06a157c974bb15f73e70e2d3740cd9b9eeb8f1421a8c9451b07364c6bfd1fbfbce5935763b53ad35fa65ab7bbbb32295582c2a4b047782d61e79203
data/.DS_Store ADDED
Binary file
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- open_api_smart_recruiters_sdk (0.2.3)
4
+ open_api_smart_recruiters_sdk (0.2.4)
5
5
  oauth2 (~> 2.0)
6
6
  typhoeus (~> 1.4)
7
7
 
data/lib/.DS_Store ADDED
Binary file
Binary file
@@ -0,0 +1,169 @@
1
+
2
+
3
+ module SmartRecruiters
4
+ class InterviewTypesApi
5
+ attr_accessor :api_client
6
+
7
+ def initialize(api_client = ApiClient.default)
8
+ @api_client = api_client
9
+ end
10
+ # Removes interview type with given name
11
+ # @param interview_type Interview type name
12
+ # @param [Hash] opts the optional parameters
13
+ # @return [nil]
14
+ def types_delete(interview_type, opts = {})
15
+ types_delete_with_http_info(interview_type, opts)
16
+ nil
17
+ end
18
+
19
+ # Removes interview type with given name
20
+ # @param interview_type Interview type name
21
+ # @param [Hash] opts the optional parameters
22
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
23
+ def types_delete_with_http_info(interview_type, opts = {})
24
+ if @api_client.config.debugging
25
+ @api_client.config.logger.debug 'Calling API: InterviewTypesApi.types_delete ...'
26
+ end
27
+ # verify the required parameter 'interview_type' is set
28
+ if @api_client.config.client_side_validation && interview_type.nil?
29
+ fail ArgumentError, "Missing the required parameter 'interview_type' when calling InterviewTypesApi.types_delete"
30
+ end
31
+ # resource path
32
+ local_var_path = '/interview-types/{interviewType}'.sub('{' + 'interviewType' + '}', interview_type.to_s)
33
+
34
+ # query parameters
35
+ query_params = opts[:query_params] || {}
36
+
37
+ # header parameters
38
+ header_params = opts[:header_params] || {}
39
+ # HTTP header 'Accept' (if needed)
40
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
41
+
42
+ # form parameters
43
+ form_params = opts[:form_params] || {}
44
+
45
+ # http body (model)
46
+ post_body = opts[:body]
47
+
48
+ return_type = opts[:return_type]
49
+
50
+ auth_names = opts[:auth_names] || ['key', 'oauth']
51
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
52
+ :header_params => header_params,
53
+ :query_params => query_params,
54
+ :form_params => form_params,
55
+ :body => post_body,
56
+ :auth_names => auth_names,
57
+ :return_type => return_type)
58
+
59
+ if @api_client.config.debugging
60
+ @api_client.config.logger.debug "API called: InterviewTypesApi#types_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
61
+ end
62
+ return data, status_code, headers
63
+ end
64
+ # Retrieves interview types
65
+ # @param [Hash] opts the optional parameters
66
+ # @return [InterviewTypes]
67
+ def types_get(opts = {})
68
+ data, _status_code, _headers = types_get_with_http_info(opts)
69
+ data
70
+ end
71
+
72
+ # Retrieves interview types
73
+ # @param [Hash] opts the optional parameters
74
+ # @return [Array<(InterviewTypes, Integer, Hash)>] InterviewTypes data, response status code and response headers
75
+ def types_get_with_http_info(opts = {})
76
+ if @api_client.config.debugging
77
+ @api_client.config.logger.debug 'Calling API: InterviewTypesApi.types_get ...'
78
+ end
79
+ # resource path
80
+ local_var_path = '/interview-types'
81
+
82
+ # query parameters
83
+ query_params = opts[:query_params] || {}
84
+
85
+ # header parameters
86
+ header_params = opts[:header_params] || {}
87
+ # HTTP header 'Accept' (if needed)
88
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
89
+
90
+ # form parameters
91
+ form_params = opts[:form_params] || {}
92
+
93
+ # http body (model)
94
+ post_body = opts[:body]
95
+
96
+ return_type = opts[:return_type] || 'InterviewTypes'
97
+
98
+ auth_names = opts[:auth_names] || ['key', 'oauth']
99
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
100
+ :header_params => header_params,
101
+ :query_params => query_params,
102
+ :form_params => form_params,
103
+ :body => post_body,
104
+ :auth_names => auth_names,
105
+ :return_type => return_type)
106
+
107
+ if @api_client.config.debugging
108
+ @api_client.config.logger.debug "API called: InterviewTypesApi#types_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
109
+ end
110
+ return data, status_code, headers
111
+ end
112
+ # Adds interview types to already existing ones
113
+ # @param body Interview types to be added
114
+ # @param [Hash] opts the optional parameters
115
+ # @return [nil]
116
+ def types_update(body, opts = {})
117
+ types_update_with_http_info(body, opts)
118
+ nil
119
+ end
120
+
121
+ # Adds interview types to already existing ones
122
+ # @param body Interview types to be added
123
+ # @param [Hash] opts the optional parameters
124
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
125
+ def types_update_with_http_info(body, opts = {})
126
+ if @api_client.config.debugging
127
+ @api_client.config.logger.debug 'Calling API: InterviewTypesApi.types_update ...'
128
+ end
129
+ # verify the required parameter 'body' is set
130
+ if @api_client.config.client_side_validation && body.nil?
131
+ fail ArgumentError, "Missing the required parameter 'body' when calling InterviewTypesApi.types_update"
132
+ end
133
+ # resource path
134
+ local_var_path = '/interview-types'
135
+
136
+ # query parameters
137
+ query_params = opts[:query_params] || {}
138
+
139
+ # header parameters
140
+ header_params = opts[:header_params] || {}
141
+ # HTTP header 'Accept' (if needed)
142
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
143
+ # HTTP header 'Content-Type'
144
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
145
+
146
+ # form parameters
147
+ form_params = opts[:form_params] || {}
148
+
149
+ # http body (model)
150
+ post_body = opts[:body] || @api_client.object_to_http_body(body)
151
+
152
+ return_type = opts[:return_type]
153
+
154
+ auth_names = opts[:auth_names] || ['key', 'oauth']
155
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
156
+ :header_params => header_params,
157
+ :query_params => query_params,
158
+ :form_params => form_params,
159
+ :body => post_body,
160
+ :auth_names => auth_names,
161
+ :return_type => return_type)
162
+
163
+ if @api_client.config.debugging
164
+ @api_client.config.logger.debug "API called: InterviewTypesApi#types_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
165
+ end
166
+ return data, status_code, headers
167
+ end
168
+ end
169
+ end
@@ -0,0 +1,296 @@
1
+
2
+
3
+ module SmartRecruiters
4
+ class InterviewsApi
5
+ attr_accessor :api_client
6
+
7
+ def initialize(api_client = ApiClient.default)
8
+ @api_client = api_client
9
+ end
10
+ # Creates an interview
11
+ # @param body Interview to be added
12
+ # @param [Hash] opts the optional parameters
13
+ # @return [Interview]
14
+ def interviews_create(body, opts = {})
15
+ data, _status_code, _headers = interviews_create_with_http_info(body, opts)
16
+ data
17
+ end
18
+
19
+ # Creates an interview
20
+ # @param body Interview to be added
21
+ # @param [Hash] opts the optional parameters
22
+ # @return [Array<(Interview, Integer, Hash)>] Interview data, response status code and response headers
23
+ def interviews_create_with_http_info(body, opts = {})
24
+ if @api_client.config.debugging
25
+ @api_client.config.logger.debug 'Calling API: InterviewsApi.interviews_create ...'
26
+ end
27
+ # verify the required parameter 'body' is set
28
+ if @api_client.config.client_side_validation && body.nil?
29
+ fail ArgumentError, "Missing the required parameter 'body' when calling InterviewsApi.interviews_create"
30
+ end
31
+ # resource path
32
+ local_var_path = '/interviews'
33
+
34
+ # query parameters
35
+ query_params = opts[:query_params] || {}
36
+
37
+ # header parameters
38
+ header_params = opts[:header_params] || {}
39
+ # HTTP header 'Accept' (if needed)
40
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
41
+ # HTTP header 'Content-Type'
42
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
43
+
44
+ # form parameters
45
+ form_params = opts[:form_params] || {}
46
+
47
+ # http body (model)
48
+ post_body = opts[:body] || @api_client.object_to_http_body(body)
49
+
50
+ return_type = opts[:return_type] || 'Interview'
51
+
52
+ auth_names = opts[:auth_names] || ['key', 'oauth']
53
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
54
+ :header_params => header_params,
55
+ :query_params => query_params,
56
+ :form_params => form_params,
57
+ :body => post_body,
58
+ :auth_names => auth_names,
59
+ :return_type => return_type)
60
+
61
+ if @api_client.config.debugging
62
+ @api_client.config.logger.debug "API called: InterviewsApi#interviews_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
63
+ end
64
+ return data, status_code, headers
65
+ end
66
+ # Deletes an interview
67
+ # @param interview_id ID of the interview
68
+ # @param [Hash] opts the optional parameters
69
+ # @return [nil]
70
+ def interviews_delete(interview_id, opts = {})
71
+ interviews_delete_with_http_info(interview_id, opts)
72
+ nil
73
+ end
74
+
75
+ # Deletes an interview
76
+ # @param interview_id ID of the interview
77
+ # @param [Hash] opts the optional parameters
78
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
79
+ def interviews_delete_with_http_info(interview_id, opts = {})
80
+ if @api_client.config.debugging
81
+ @api_client.config.logger.debug 'Calling API: InterviewsApi.interviews_delete ...'
82
+ end
83
+ # verify the required parameter 'interview_id' is set
84
+ if @api_client.config.client_side_validation && interview_id.nil?
85
+ fail ArgumentError, "Missing the required parameter 'interview_id' when calling InterviewsApi.interviews_delete"
86
+ end
87
+ # resource path
88
+ local_var_path = '/interviews/{interviewId}'.sub('{' + 'interviewId' + '}', interview_id.to_s)
89
+
90
+ # query parameters
91
+ query_params = opts[:query_params] || {}
92
+
93
+ # header parameters
94
+ header_params = opts[:header_params] || {}
95
+ # HTTP header 'Accept' (if needed)
96
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
97
+
98
+ # form parameters
99
+ form_params = opts[:form_params] || {}
100
+
101
+ # http body (model)
102
+ post_body = opts[:body]
103
+
104
+ return_type = opts[:return_type]
105
+
106
+ auth_names = opts[:auth_names] || ['key', 'oauth']
107
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
108
+ :header_params => header_params,
109
+ :query_params => query_params,
110
+ :form_params => form_params,
111
+ :body => post_body,
112
+ :auth_names => auth_names,
113
+ :return_type => return_type)
114
+
115
+ if @api_client.config.debugging
116
+ @api_client.config.logger.debug "API called: InterviewsApi#interviews_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
117
+ end
118
+ return data, status_code, headers
119
+ end
120
+ # Retrieves an interview
121
+ # Interview details
122
+ # @param interview_id ID of the interview
123
+ # @param [Hash] opts the optional parameters
124
+ # @return [Interview]
125
+ def interviews_get(interview_id, opts = {})
126
+ data, _status_code, _headers = interviews_get_with_http_info(interview_id, opts)
127
+ data
128
+ end
129
+
130
+ # Retrieves an interview
131
+ # Interview details
132
+ # @param interview_id ID of the interview
133
+ # @param [Hash] opts the optional parameters
134
+ # @return [Array<(Interview, Integer, Hash)>] Interview data, response status code and response headers
135
+ def interviews_get_with_http_info(interview_id, opts = {})
136
+ if @api_client.config.debugging
137
+ @api_client.config.logger.debug 'Calling API: InterviewsApi.interviews_get ...'
138
+ end
139
+ # verify the required parameter 'interview_id' is set
140
+ if @api_client.config.client_side_validation && interview_id.nil?
141
+ fail ArgumentError, "Missing the required parameter 'interview_id' when calling InterviewsApi.interviews_get"
142
+ end
143
+ # resource path
144
+ local_var_path = '/interviews/{interviewId}'.sub('{' + 'interviewId' + '}', interview_id.to_s)
145
+
146
+ # query parameters
147
+ query_params = opts[:query_params] || {}
148
+
149
+ # header parameters
150
+ header_params = opts[:header_params] || {}
151
+ # HTTP header 'Accept' (if needed)
152
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
153
+
154
+ # form parameters
155
+ form_params = opts[:form_params] || {}
156
+
157
+ # http body (model)
158
+ post_body = opts[:body]
159
+
160
+ return_type = opts[:return_type] || 'Interview'
161
+
162
+ auth_names = opts[:auth_names] || ['key', 'oauth']
163
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
164
+ :header_params => header_params,
165
+ :query_params => query_params,
166
+ :form_params => form_params,
167
+ :body => post_body,
168
+ :auth_names => auth_names,
169
+ :return_type => return_type)
170
+
171
+ if @api_client.config.debugging
172
+ @api_client.config.logger.debug "API called: InterviewsApi#interviews_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
173
+ end
174
+ return data, status_code, headers
175
+ end
176
+ # Retrieves a list of interviews
177
+ # List of interviews
178
+ # @param application_id ID of the application
179
+ # @param [Hash] opts the optional parameters
180
+ # @return [InterviewsList]
181
+ def interviews_get_list(application_id, opts = {})
182
+ data, _status_code, _headers = interviews_get_list_with_http_info(application_id, opts)
183
+ data
184
+ end
185
+
186
+ # Retrieves a list of interviews
187
+ # List of interviews
188
+ # @param application_id ID of the application
189
+ # @param [Hash] opts the optional parameters
190
+ # @return [Array<(InterviewsList, Integer, Hash)>] InterviewsList data, response status code and response headers
191
+ def interviews_get_list_with_http_info(application_id, opts = {})
192
+ if @api_client.config.debugging
193
+ @api_client.config.logger.debug 'Calling API: InterviewsApi.interviews_get_list ...'
194
+ end
195
+ # verify the required parameter 'application_id' is set
196
+ if @api_client.config.client_side_validation && application_id.nil?
197
+ fail ArgumentError, "Missing the required parameter 'application_id' when calling InterviewsApi.interviews_get_list"
198
+ end
199
+ # resource path
200
+ local_var_path = '/interviews'
201
+
202
+ # query parameters
203
+ query_params = opts[:query_params] || {}
204
+ query_params[:'applicationId'] = application_id
205
+
206
+ # header parameters
207
+ header_params = opts[:header_params] || {}
208
+ # HTTP header 'Accept' (if needed)
209
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
210
+
211
+ # form parameters
212
+ form_params = opts[:form_params] || {}
213
+
214
+ # http body (model)
215
+ post_body = opts[:body]
216
+
217
+ return_type = opts[:return_type] || 'InterviewsList'
218
+
219
+ auth_names = opts[:auth_names] || ['key', 'oauth']
220
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
221
+ :header_params => header_params,
222
+ :query_params => query_params,
223
+ :form_params => form_params,
224
+ :body => post_body,
225
+ :auth_names => auth_names,
226
+ :return_type => return_type)
227
+
228
+ if @api_client.config.debugging
229
+ @api_client.config.logger.debug "API called: InterviewsApi#interviews_get_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
230
+ end
231
+ return data, status_code, headers
232
+ end
233
+ # Modifies an interview
234
+ # @param body Interview to be updated
235
+ # @param interview_id ID of the interview
236
+ # @param [Hash] opts the optional parameters
237
+ # @return [nil]
238
+ def interviews_update(body, interview_id, opts = {})
239
+ interviews_update_with_http_info(body, interview_id, opts)
240
+ nil
241
+ end
242
+
243
+ # Modifies an interview
244
+ # @param body Interview to be updated
245
+ # @param interview_id ID of the interview
246
+ # @param [Hash] opts the optional parameters
247
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
248
+ def interviews_update_with_http_info(body, interview_id, opts = {})
249
+ if @api_client.config.debugging
250
+ @api_client.config.logger.debug 'Calling API: InterviewsApi.interviews_update ...'
251
+ end
252
+ # verify the required parameter 'body' is set
253
+ if @api_client.config.client_side_validation && body.nil?
254
+ fail ArgumentError, "Missing the required parameter 'body' when calling InterviewsApi.interviews_update"
255
+ end
256
+ # verify the required parameter 'interview_id' is set
257
+ if @api_client.config.client_side_validation && interview_id.nil?
258
+ fail ArgumentError, "Missing the required parameter 'interview_id' when calling InterviewsApi.interviews_update"
259
+ end
260
+ # resource path
261
+ local_var_path = '/interviews/{interviewId}'.sub('{' + 'interviewId' + '}', interview_id.to_s)
262
+
263
+ # query parameters
264
+ query_params = opts[:query_params] || {}
265
+
266
+ # header parameters
267
+ header_params = opts[:header_params] || {}
268
+ # HTTP header 'Accept' (if needed)
269
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
270
+ # HTTP header 'Content-Type'
271
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
272
+
273
+ # form parameters
274
+ form_params = opts[:form_params] || {}
275
+
276
+ # http body (model)
277
+ post_body = opts[:body] || @api_client.object_to_http_body(body)
278
+
279
+ return_type = opts[:return_type]
280
+
281
+ auth_names = opts[:auth_names] || ['key', 'oauth']
282
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
283
+ :header_params => header_params,
284
+ :query_params => query_params,
285
+ :form_params => form_params,
286
+ :body => post_body,
287
+ :auth_names => auth_names,
288
+ :return_type => return_type)
289
+
290
+ if @api_client.config.debugging
291
+ @api_client.config.logger.debug "API called: InterviewsApi#interviews_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
292
+ end
293
+ return data, status_code, headers
294
+ end
295
+ end
296
+ end
@@ -0,0 +1,187 @@
1
+
2
+
3
+ module SmartRecruiters
4
+ class MessagesApi
5
+ attr_accessor :api_client
6
+
7
+ def initialize(api_client = ApiClient.default)
8
+ @api_client = api_client
9
+ end
10
+ # Fetch messages
11
+ # Search for messages of given candidate. Use jobId parameter to filter results to messages only for specific job application. Accessible only for users with ADMINISTRATOR role.
12
+ # @param candidate_id identifier of a candidate
13
+ # @param [Hash] opts the optional parameters
14
+ # @option opts [String] :job_id identifier of a job
15
+ # @option opts [String] :page_id identifier of next page
16
+ # @option opts [Integer] :limit limit (default to 10)
17
+ # @return [MessagesView]
18
+ def messages_fetch(candidate_id, opts = {})
19
+ data, _status_code, _headers = messages_fetch_with_http_info(candidate_id, opts)
20
+ data
21
+ end
22
+
23
+ # Fetch messages
24
+ # Search for messages of given candidate. Use jobId parameter to filter results to messages only for specific job application. Accessible only for users with ADMINISTRATOR role.
25
+ # @param candidate_id identifier of a candidate
26
+ # @param [Hash] opts the optional parameters
27
+ # @option opts [String] :job_id identifier of a job
28
+ # @option opts [String] :page_id identifier of next page
29
+ # @option opts [Integer] :limit limit
30
+ # @return [Array<(MessagesView, Integer, Hash)>] MessagesView data, response status code and response headers
31
+ def messages_fetch_with_http_info(candidate_id, opts = {})
32
+ if @api_client.config.debugging
33
+ @api_client.config.logger.debug 'Calling API: MessagesApi.messages_fetch ...'
34
+ end
35
+ # verify the required parameter 'candidate_id' is set
36
+ if @api_client.config.client_side_validation && candidate_id.nil?
37
+ fail ArgumentError, "Missing the required parameter 'candidate_id' when calling MessagesApi.messages_fetch"
38
+ end
39
+ # resource path
40
+ local_var_path = '/messages'
41
+
42
+ # query parameters
43
+ query_params = opts[:query_params] || {}
44
+ query_params[:'candidateId'] = candidate_id
45
+ query_params[:'jobId'] = opts[:'job_id'] if !opts[:'job_id'].nil?
46
+ query_params[:'pageId'] = opts[:'page_id'] if !opts[:'page_id'].nil?
47
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
48
+
49
+ # header parameters
50
+ header_params = opts[:header_params] || {}
51
+ # HTTP header 'Accept' (if needed)
52
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
53
+
54
+ # form parameters
55
+ form_params = opts[:form_params] || {}
56
+
57
+ # http body (model)
58
+ post_body = opts[:body]
59
+
60
+ return_type = opts[:return_type] || 'MessagesView'
61
+
62
+ auth_names = opts[:auth_names] || ['key', 'oauth']
63
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
64
+ :header_params => header_params,
65
+ :query_params => query_params,
66
+ :form_params => form_params,
67
+ :body => post_body,
68
+ :auth_names => auth_names,
69
+ :return_type => return_type)
70
+
71
+ if @api_client.config.debugging
72
+ @api_client.config.logger.debug "API called: MessagesApi#messages_fetch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
73
+ end
74
+ return data, status_code, headers
75
+ end
76
+ # Shares new messages on Hireloop with Users, Hiring Teams or Everyone and sends emails.
77
+ # How does it work: * In **content** field, provide a text to be shared. * @-mention users to send them an email * In **content** field use **@[USER:id]** to mention a User, e.g. @[USER:324132421] * Email responses are added as comments to your update * \\#-tag candidates to link updates to their profiles * In **content** field use **#[CANDIDATE:id]** to tag a candidate, e.g. #[CANDIDATE:9847954623] * Use **shareWith** to share a feed update with individuals, hiring teams or everyone * In **users** field, provide an array of User IDs with which you want to share, e.g. \"users\": [\"12343542356\",\"12343542357\"]. * In **hiringTeamOf** field, provide an array of Job IDs, this will share message with a full hiring team of those jobs, e.g. \"hiringTeamOf\": [\"123423432322\",\"123423432324\"]. * **everyone** flag allows sharing with everyone in a company. If not provided, defaults to **false**. * **openNote** flag allows sharing with everyone in a company that has access to the candidate. If not provided, defaults to **false**
78
+ # @param [Hash] opts the optional parameters
79
+ # @option opts [Message] :body Message to post
80
+ # @return [MessageDetails]
81
+ def messages_shares_create(opts = {})
82
+ data, _status_code, _headers = messages_shares_create_with_http_info(opts)
83
+ data
84
+ end
85
+
86
+ # Shares new messages on Hireloop with Users, Hiring Teams or Everyone and sends emails.
87
+ # How does it work: * In **content** field, provide a text to be shared. * @-mention users to send them an email * In **content** field use **@[USER:id]** to mention a User, e.g. @[USER:324132421] * Email responses are added as comments to your update * \\#-tag candidates to link updates to their profiles * In **content** field use **#[CANDIDATE:id]** to tag a candidate, e.g. #[CANDIDATE:9847954623] * Use **shareWith** to share a feed update with individuals, hiring teams or everyone * In **users** field, provide an array of User IDs with which you want to share, e.g. \&quot;users\&quot;: [\&quot;12343542356\&quot;,\&quot;12343542357\&quot;]. * In **hiringTeamOf** field, provide an array of Job IDs, this will share message with a full hiring team of those jobs, e.g. \&quot;hiringTeamOf\&quot;: [\&quot;123423432322\&quot;,\&quot;123423432324\&quot;]. * **everyone** flag allows sharing with everyone in a company. If not provided, defaults to **false**. * **openNote** flag allows sharing with everyone in a company that has access to the candidate. If not provided, defaults to **false**
88
+ # @param [Hash] opts the optional parameters
89
+ # @option opts [Message] :body Message to post
90
+ # @return [Array<(MessageDetails, Integer, Hash)>] MessageDetails data, response status code and response headers
91
+ def messages_shares_create_with_http_info(opts = {})
92
+ if @api_client.config.debugging
93
+ @api_client.config.logger.debug 'Calling API: MessagesApi.messages_shares_create ...'
94
+ end
95
+ # resource path
96
+ local_var_path = '/messages/shares'
97
+
98
+ # query parameters
99
+ query_params = opts[:query_params] || {}
100
+
101
+ # header parameters
102
+ header_params = opts[:header_params] || {}
103
+ # HTTP header 'Accept' (if needed)
104
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
105
+ # HTTP header 'Content-Type'
106
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
107
+
108
+ # form parameters
109
+ form_params = opts[:form_params] || {}
110
+
111
+ # http body (model)
112
+ post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body'])
113
+
114
+ return_type = opts[:return_type] || 'MessageDetails'
115
+
116
+ auth_names = opts[:auth_names] || ['key', 'oauth']
117
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
118
+ :header_params => header_params,
119
+ :query_params => query_params,
120
+ :form_params => form_params,
121
+ :body => post_body,
122
+ :auth_names => auth_names,
123
+ :return_type => return_type)
124
+
125
+ if @api_client.config.debugging
126
+ @api_client.config.logger.debug "API called: MessagesApi#messages_shares_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
127
+ end
128
+ return data, status_code, headers
129
+ end
130
+ # Delete a message
131
+ # Delete a message with a given id. Deleted message is no longer visible on Hireloop.
132
+ # @param id identifier of a message
133
+ # @param [Hash] opts the optional parameters
134
+ # @return [nil]
135
+ def messages_shares_delete(id, opts = {})
136
+ messages_shares_delete_with_http_info(id, opts)
137
+ nil
138
+ end
139
+
140
+ # Delete a message
141
+ # Delete a message with a given id. Deleted message is no longer visible on Hireloop.
142
+ # @param id identifier of a message
143
+ # @param [Hash] opts the optional parameters
144
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
145
+ def messages_shares_delete_with_http_info(id, opts = {})
146
+ if @api_client.config.debugging
147
+ @api_client.config.logger.debug 'Calling API: MessagesApi.messages_shares_delete ...'
148
+ end
149
+ # verify the required parameter 'id' is set
150
+ if @api_client.config.client_side_validation && id.nil?
151
+ fail ArgumentError, "Missing the required parameter 'id' when calling MessagesApi.messages_shares_delete"
152
+ end
153
+ # resource path
154
+ local_var_path = '/messages/shares/{id}'.sub('{' + 'id' + '}', id.to_s)
155
+
156
+ # query parameters
157
+ query_params = opts[:query_params] || {}
158
+
159
+ # header parameters
160
+ header_params = opts[:header_params] || {}
161
+ # HTTP header 'Accept' (if needed)
162
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
163
+
164
+ # form parameters
165
+ form_params = opts[:form_params] || {}
166
+
167
+ # http body (model)
168
+ post_body = opts[:body]
169
+
170
+ return_type = opts[:return_type]
171
+
172
+ auth_names = opts[:auth_names] || ['key', 'oauth']
173
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
174
+ :header_params => header_params,
175
+ :query_params => query_params,
176
+ :form_params => form_params,
177
+ :body => post_body,
178
+ :auth_names => auth_names,
179
+ :return_type => return_type)
180
+
181
+ if @api_client.config.debugging
182
+ @api_client.config.logger.debug "API called: MessagesApi#messages_shares_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
183
+ end
184
+ return data, status_code, headers
185
+ end
186
+ end
187
+ end