Class: TripletexApi::ProjectApi

Inherits:
Object
  • Object
show all
Defined in:
lib/tripletex_api/api/project_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ ProjectApi

Returns a new instance of ProjectApi.



19
20
21
# File 'lib/tripletex_api/api/project_api.rb', line 19

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/tripletex_api/api/project_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#delete(id, opts = {}) ⇒ nil

BETA

Delete project.

Parameters:

  • id

    Element ID

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (nil)


28
29
30
31
# File 'lib/tripletex_api/api/project_api.rb', line 28

def delete(id, opts = {})
  delete_with_http_info(id, opts)
  return nil
end

#delete_by_ids(ids, opts = {}) ⇒ nil

BETA

Delete projects.

Parameters:

  • ids

    ID of the elements

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (nil)


78
79
80
81
# File 'lib/tripletex_api/api/project_api.rb', line 78

def delete_by_ids(ids, opts = {})
  delete_by_ids_with_http_info(ids, opts)
  return nil
end

#delete_by_ids_with_http_info(ids, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

BETA

Delete projects.

Parameters:

  • ids

    ID of the elements

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'lib/tripletex_api/api/project_api.rb', line 88

def delete_by_ids_with_http_info(ids, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.delete_by_ids ..."
  end
  # verify the required parameter 'ids' is set
  if @api_client.config.client_side_validation && ids.nil?
    fail ArgumentError, "Missing the required parameter 'ids' when calling ProjectApi.delete_by_ids"
  end
  # resource path
  local_var_path = "/project/list"

  # query parameters
  query_params = {}
  query_params[:'ids'] = ids

  # header parameters
  header_params = {}

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#delete_by_ids\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_list(opts = {}) ⇒ nil

BETA

Delete multiple projects.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Array<Project>)

    JSON representing objects to delete. Should have ID and version set.

Returns:

  • (nil)


129
130
131
132
# File 'lib/tripletex_api/api/project_api.rb', line 129

def delete_list(opts = {})
  delete_list_with_http_info(opts)
  return nil
end

#delete_list_with_http_info(opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

BETA

Delete multiple projects.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Array<Project>)

    JSON representing objects to delete. Should have ID and version set.

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
# File 'lib/tripletex_api/api/project_api.rb', line 139

def delete_list_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.delete_list ..."
  end
  # resource path
  local_var_path = "/project"

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(opts[:'body'])
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#delete_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_with_http_info(id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

BETA

Delete project.

Parameters:

  • id

    Element ID

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# File 'lib/tripletex_api/api/project_api.rb', line 38

def delete_with_http_info(id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.delete ..."
  end
  # verify the required parameter 'id' is set
  if @api_client.config.client_side_validation && id.nil?
    fail ArgumentError, "Missing the required parameter 'id' when calling ProjectApi.delete"
  end
  # resource path
  local_var_path = "/project/{id}".sub('{' + 'id' + '}', id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get(id, opts = {}) ⇒ ResponseWrapperProject

Find project by ID.

Parameters:

  • id

    Element ID

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :fields (String)

    Fields filter pattern

Returns:



178
179
180
181
# File 'lib/tripletex_api/api/project_api.rb', line 178

def get(id, opts = {})
  data, _status_code, _headers = get_with_http_info(id, opts)
  return data
end

#get_for_time_sheet(opts = {}) ⇒ ListResponseProject

Find projects applicable for time sheet registration on a specific day.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :employee_id (Integer)

    Employee ID. Defaults to ID of token owner.

  • :date (String)

    yyyy-MM-dd. Defaults to today.

  • :from (Integer)

    From index (default to 0)

  • :count (Integer)

    Number of elements to return (default to 1000)

  • :sorting (String)

    Sorting pattern

  • :fields (String)

    Fields filter pattern

Returns:



236
237
238
239
# File 'lib/tripletex_api/api/project_api.rb', line 236

def get_for_time_sheet(opts = {})
  data, _status_code, _headers = get_for_time_sheet_with_http_info(opts)
  return data
end

#get_for_time_sheet_with_http_info(opts = {}) ⇒ Array<(ListResponseProject, Fixnum, Hash)>

Find projects applicable for time sheet registration on a specific day.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :employee_id (Integer)

    Employee ID. Defaults to ID of token owner.

  • :date (String)

    yyyy-MM-dd. Defaults to today.

  • :from (Integer)

    From index

  • :count (Integer)

    Number of elements to return

  • :sorting (String)

    Sorting pattern

  • :fields (String)

    Fields filter pattern

Returns:

  • (Array<(ListResponseProject, Fixnum, Hash)>)

    ListResponseProject data, response status code and response headers



251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
# File 'lib/tripletex_api/api/project_api.rb', line 251

def get_for_time_sheet_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.get_for_time_sheet ..."
  end
  # resource path
  local_var_path = "/project/>forTimeSheet"

  # query parameters
  query_params = {}
  query_params[:'employeeId'] = opts[:'employee_id'] if !opts[:'employee_id'].nil?
  query_params[:'date'] = opts[:'date'] if !opts[:'date'].nil?
  query_params[:'from'] = opts[:'from'] if !opts[:'from'].nil?
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
  query_params[:'sorting'] = opts[:'sorting'] if !opts[:'sorting'].nil?
  query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?

  # header parameters
  header_params = {}

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ListResponseProject')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#get_for_time_sheet\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_with_http_info(id, opts = {}) ⇒ Array<(ResponseWrapperProject, Fixnum, Hash)>

Find project by ID.

Parameters:

  • id

    Element ID

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :fields (String)

    Fields filter pattern

Returns:

  • (Array<(ResponseWrapperProject, Fixnum, Hash)>)

    ResponseWrapperProject data, response status code and response headers



189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
# File 'lib/tripletex_api/api/project_api.rb', line 189

def get_with_http_info(id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.get ..."
  end
  # verify the required parameter 'id' is set
  if @api_client.config.client_side_validation && id.nil?
    fail ArgumentError, "Missing the required parameter 'id' when calling ProjectApi.get"
  end
  # resource path
  local_var_path = "/project/{id}".sub('{' + 'id' + '}', id.to_s)

  # query parameters
  query_params = {}
  query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?

  # header parameters
  header_params = {}

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ResponseWrapperProject')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#post(opts = {}) ⇒ ResponseWrapperProject

BETA

Add new project.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Project)

    JSON representing the new object to be created. Should not have ID and version set.

Returns:



294
295
296
297
# File 'lib/tripletex_api/api/project_api.rb', line 294

def post(opts = {})
  data, _status_code, _headers = post_with_http_info(opts)
  return data
end

#post_list(opts = {}) ⇒ ListResponseProject

BETA

Register new projects. Multiple projects for different users can be sent in the same request.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Array<Project>)

    JSON representing a list of new object to be created. Should not have ID and version set.

Returns:



343
344
345
346
# File 'lib/tripletex_api/api/project_api.rb', line 343

def post_list(opts = {})
  data, _status_code, _headers = post_list_with_http_info(opts)
  return data
end

#post_list_with_http_info(opts = {}) ⇒ Array<(ListResponseProject, Fixnum, Hash)>

BETA

Register new projects. Multiple projects for different users can be sent in the same request.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Array<Project>)

    JSON representing a list of new object to be created. Should not have ID and version set.

Returns:

  • (Array<(ListResponseProject, Fixnum, Hash)>)

    ListResponseProject data, response status code and response headers



353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
# File 'lib/tripletex_api/api/project_api.rb', line 353

def post_list_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.post_list ..."
  end
  # resource path
  local_var_path = "/project/list"

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(opts[:'body'])
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ListResponseProject')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#post_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#post_with_http_info(opts = {}) ⇒ Array<(ResponseWrapperProject, Fixnum, Hash)>

BETA

Add new project.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Project)

    JSON representing the new object to be created. Should not have ID and version set.

Returns:

  • (Array<(ResponseWrapperProject, Fixnum, Hash)>)

    ResponseWrapperProject data, response status code and response headers



304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
# File 'lib/tripletex_api/api/project_api.rb', line 304

def post_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.post ..."
  end
  # resource path
  local_var_path = "/project"

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(opts[:'body'])
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ResponseWrapperProject')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put(id, opts = {}) ⇒ ResponseWrapperProject

BETA

Update project.

Parameters:

  • id

    Element ID

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Project)

    Partial object describing what should be updated

Returns:



393
394
395
396
# File 'lib/tripletex_api/api/project_api.rb', line 393

def put(id, opts = {})
  data, _status_code, _headers = put_with_http_info(id, opts)
  return data
end

#put_list(opts = {}) ⇒ ListResponseProject

BETA

Update multiple projects.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Array<Project>)

    JSON representing updates to object. Should have ID and version set.

Returns:



447
448
449
450
# File 'lib/tripletex_api/api/project_api.rb', line 447

def put_list(opts = {})
  data, _status_code, _headers = put_list_with_http_info(opts)
  return data
end

#put_list_with_http_info(opts = {}) ⇒ Array<(ListResponseProject, Fixnum, Hash)>

BETA

Update multiple projects.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Array<Project>)

    JSON representing updates to object. Should have ID and version set.

Returns:

  • (Array<(ListResponseProject, Fixnum, Hash)>)

    ListResponseProject data, response status code and response headers



457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
# File 'lib/tripletex_api/api/project_api.rb', line 457

def put_list_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.put_list ..."
  end
  # resource path
  local_var_path = "/project/list"

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(opts[:'body'])
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ListResponseProject')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#put_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_with_http_info(id, opts = {}) ⇒ Array<(ResponseWrapperProject, Fixnum, Hash)>

BETA

Update project.

Parameters:

  • id

    Element ID

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :body (Project)

    Partial object describing what should be updated

Returns:

  • (Array<(ResponseWrapperProject, Fixnum, Hash)>)

    ResponseWrapperProject data, response status code and response headers



404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
# File 'lib/tripletex_api/api/project_api.rb', line 404

def put_with_http_info(id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.put ..."
  end
  # verify the required parameter 'id' is set
  if @api_client.config.client_side_validation && id.nil?
    fail ArgumentError, "Missing the required parameter 'id' when calling ProjectApi.put"
  end
  # resource path
  local_var_path = "/project/{id}".sub('{' + 'id' + '}', id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json; charset=utf-8'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(opts[:'body'])
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ResponseWrapperProject')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#put\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#search(opts = {}) ⇒ ListResponseProject

Find projects corresponding with sent data.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :id (String)

    List of IDs

  • :name (String)

    Containing

  • :number (String)

    Equals

  • :is_offer (BOOLEAN)

    Equals

  • :project_manager_id (String)

    List of IDs

  • :employee_in_project_id (String)

    List of IDs

  • :department_id (String)

    List of IDs

  • :start_date_from (String)

    From and including

  • :start_date_to (String)

    To and excluding

  • :end_date_from (String)

    From and including

  • :end_date_to (String)

    To and excluding

  • :is_closed (BOOLEAN)

    Equals

  • :customer_id (String)

    Equals

  • :external_accounts_number (String)

    Containing

  • :from (Integer)

    From index (default to 0)

  • :count (Integer)

    Number of elements to return (default to 1000)

  • :sorting (String)

    Sorting pattern

  • :fields (String)

    Fields filter pattern

Returns:



513
514
515
516
# File 'lib/tripletex_api/api/project_api.rb', line 513

def search(opts = {})
  data, _status_code, _headers = search_with_http_info(opts)
  return data
end

#search_with_http_info(opts = {}) ⇒ Array<(ListResponseProject, Fixnum, Hash)>

Find projects corresponding with sent data.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :id (String)

    List of IDs

  • :name (String)

    Containing

  • :number (String)

    Equals

  • :is_offer (BOOLEAN)

    Equals

  • :project_manager_id (String)

    List of IDs

  • :employee_in_project_id (String)

    List of IDs

  • :department_id (String)

    List of IDs

  • :start_date_from (String)

    From and including

  • :start_date_to (String)

    To and excluding

  • :end_date_from (String)

    From and including

  • :end_date_to (String)

    To and excluding

  • :is_closed (BOOLEAN)

    Equals

  • :customer_id (String)

    Equals

  • :external_accounts_number (String)

    Containing

  • :from (Integer)

    From index

  • :count (Integer)

    Number of elements to return

  • :sorting (String)

    Sorting pattern

  • :fields (String)

    Fields filter pattern

Returns:

  • (Array<(ListResponseProject, Fixnum, Hash)>)

    ListResponseProject data, response status code and response headers



540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
# File 'lib/tripletex_api/api/project_api.rb', line 540

def search_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: ProjectApi.search ..."
  end
  # resource path
  local_var_path = "/project"

  # query parameters
  query_params = {}
  query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil?
  query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
  query_params[:'number'] = opts[:'number'] if !opts[:'number'].nil?
  query_params[:'isOffer'] = opts[:'is_offer'] if !opts[:'is_offer'].nil?
  query_params[:'projectManagerId'] = opts[:'project_manager_id'] if !opts[:'project_manager_id'].nil?
  query_params[:'employeeInProjectId'] = opts[:'employee_in_project_id'] if !opts[:'employee_in_project_id'].nil?
  query_params[:'departmentId'] = opts[:'department_id'] if !opts[:'department_id'].nil?
  query_params[:'startDateFrom'] = opts[:'start_date_from'] if !opts[:'start_date_from'].nil?
  query_params[:'startDateTo'] = opts[:'start_date_to'] if !opts[:'start_date_to'].nil?
  query_params[:'endDateFrom'] = opts[:'end_date_from'] if !opts[:'end_date_from'].nil?
  query_params[:'endDateTo'] = opts[:'end_date_to'] if !opts[:'end_date_to'].nil?
  query_params[:'isClosed'] = opts[:'is_closed'] if !opts[:'is_closed'].nil?
  query_params[:'customerId'] = opts[:'customer_id'] if !opts[:'customer_id'].nil?
  query_params[:'externalAccountsNumber'] = opts[:'external_accounts_number'] if !opts[:'external_accounts_number'].nil?
  query_params[:'from'] = opts[:'from'] if !opts[:'from'].nil?
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
  query_params[:'sorting'] = opts[:'sorting'] if !opts[:'sorting'].nil?
  query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?

  # header parameters
  header_params = {}

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['tokenAuthScheme']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'ListResponseProject')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: ProjectApi#search\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end